Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@canvas-js/interfaces

Package Overview
Dependencies
Maintainers
3
Versions
221
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@canvas-js/interfaces - npm Package Compare versions

Comparing version 0.0.23 to 0.0.24

10

lib/actions.d.ts
import type { Chain, ChainId } from "./contracts.js";
export declare type ActionArgument = null | boolean | number | string;
export declare type Block = {
export type ActionArgument = null | boolean | number | string;
export type Block = {
chain: Chain;

@@ -10,3 +10,3 @@ chainId: ChainId;

};
export declare type ActionContext = {
export type ActionContext = {
from: string;

@@ -17,7 +17,7 @@ spec: string;

};
export declare type ActionPayload = ActionContext & {
export type ActionPayload = ActionContext & {
call: string;
args: ActionArgument[];
};
export declare type Action = {
export type Action = {
payload: ActionPayload;

@@ -24,0 +24,0 @@ session: string | null;

@@ -1,4 +0,4 @@

export declare type Chain = "eth" | "cosmos" | "solana" | "substrate";
export declare type ChainId = number | string;
export declare type ContractMetadata = {
export type Chain = "eth" | "cosmos" | "solana" | "substrate";
export type ChainId = number | string;
export type ContractMetadata = {
chain: Chain;

@@ -5,0 +5,0 @@ chainId: ChainId;

@@ -8,3 +8,3 @@ export * from "./sessions.js";

import type { Action } from "./actions.js";
export declare type Message = ({
export type Message = ({
type: "session";

@@ -11,0 +11,0 @@ } & Session) | ({

@@ -1,5 +0,5 @@

export declare type ModelType = "boolean" | "string" | "integer" | "float" | "datetime";
export declare type IndexType = string[];
export declare type ModelValue = null | boolean | number | string;
export declare type Model = {
export type ModelType = "boolean" | "string" | "integer" | "float" | "datetime";
export type IndexType = string[];
export type ModelValue = null | boolean | number | string;
export type Model = {
id: "string";

@@ -6,0 +6,0 @@ updated_at: "datetime";

import type { Block } from "./actions.js";
export declare type SessionPayload = {
export type SessionPayload = {
from: string;

@@ -10,5 +10,5 @@ spec: string;

};
export declare type Session = {
export type Session = {
payload: SessionPayload;
signature: string;
};
import { TypedDataDomain, TypedDataField } from "ethers";
import type { Action, ActionPayload } from "./actions.js";
import type { Session, SessionPayload } from "./sessions.js";
declare type SignatureData = [TypedDataDomain, Record<string, TypedDataField[]>, Record<string, string | string[]>];
type SignatureData = [TypedDataDomain, Record<string, TypedDataField[]>, Record<string, string | string[]>];
export declare function getActionSignatureData(payload: ActionPayload): SignatureData;

@@ -6,0 +6,0 @@ export declare function verifyActionSignature(action: Action): string;

{
"name": "@canvas-js/interfaces",
"version": "0.0.23",
"version": "0.0.24",
"type": "module",

@@ -5,0 +5,0 @@ "author": "Canvas Technology Corporation (https://canvas.xyz)",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc