@ucanto/server
Advanced tools
Comparing version 0.5.0 to 0.6.0
{ | ||
"name": "@ucanto/server", | ||
"description": "UCAN RPC Server", | ||
"version": "0.5.0", | ||
"version": "0.6.0", | ||
"types": "./dist/src/lib.d.ts", | ||
@@ -23,5 +23,5 @@ "main": "./src/lib.js", | ||
"dependencies": { | ||
"@ucanto/interface": "^0.5.0", | ||
"@ucanto/core": "^0.5.0", | ||
"@ucanto/validator": "^0.5.0" | ||
"@ucanto/interface": "^0.6.0", | ||
"@ucanto/core": "^0.5.1", | ||
"@ucanto/validator": "^0.5.1" | ||
}, | ||
@@ -41,5 +41,5 @@ "devDependencies": { | ||
"typescript": "^4.7.2", | ||
"@ucanto/client": "^0.4.0", | ||
"@ucanto/transport": "^0.5.0", | ||
"@ucanto/authority": "^0.4.1", | ||
"@ucanto/client": "^0.5.0", | ||
"@ucanto/transport": "^0.6.0", | ||
"@ucanto/authority": "^0.4.2", | ||
"multiformats": "^9.6.4" | ||
@@ -46,0 +46,0 @@ }, |
import * as API from '@ucanto/interface' | ||
import { InferCaveats, CanIssue } from '@ucanto/interface' | ||
import { InferCaveats, CanIssue, ParsedCapability } from '@ucanto/interface' | ||
@@ -31,1 +31,8 @@ export * from '@ucanto/interface' | ||
} | ||
export interface ProviderInput<T extends ParsedCapability> { | ||
capability: T | ||
invocation: API.Invocation<API.Capability<T['can'], T['with']> & T['caveats']> | ||
context: API.InvocationContext | ||
} |
@@ -5,11 +5,7 @@ import * as API from './api.js' | ||
/** | ||
* @template {API.Ability} A | ||
* @template {API.Caveats} C | ||
* @template {API.URI} R | ||
* @template {API.ParsedCapability} T | ||
* @template {unknown} U | ||
* @template {API.Match} Z | ||
* @template {API.ParsedCapability<A, R, API.InferCaveats<C>>} T | ||
* @param {API.CapabilityParser<API.Match<T, Z>>} capability | ||
* @param {(input:API.ProviderContext<A, R, C>) => API.Await<U>} handler | ||
* @returns {API.ServiceMethod<API.Capability<A, R['href']> & API.InferCaveats<C>, Exclude<U, {error:true}>, Exclude<U, Exclude<U, {error:true}>>>} | ||
* @param {API.CapabilityParser<API.Match<T>>} capability | ||
* @param {(input:API.ProviderInput<T>) => API.Await<U>} handler | ||
* @returns {API.ServiceMethod<API.Capability<T['can'], T['with']> & T['caveats'], Exclude<U, {error:true}>, Exclude<U, Exclude<U, {error:true}>>>} | ||
*/ | ||
@@ -22,3 +18,2 @@ | ||
* @param {API.InvocationContext} options | ||
* @return {Promise<API.Result<Exclude<U, {error:true}>, Exclude<U, Exclude<U, {error:true}>>|API.InvocationError>>} | ||
*/ | ||
@@ -25,0 +20,0 @@ async (invocation, options) => { |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
9467
- Removed@ucanto/interface@0.5.0(transitive)
Updated@ucanto/core@^0.5.1
Updated@ucanto/interface@^0.6.0
Updated@ucanto/validator@^0.5.1