├── .nojekyll ├── docs ├── .nojekyll ├── assets │ └── images │ │ ├── icons.png │ │ ├── widgets.png │ │ ├── icons@2x.png │ │ └── widgets@2x.png ├── globals.html ├── modules │ ├── _marks_.html │ ├── _util_.html │ ├── _channel_.html │ ├── _setup_.html │ └── _index_.html ├── interfaces │ ├── _marks_.marks.html │ ├── _util_.config.html │ ├── _marks_.cage.html │ ├── _channel_.subscriptioneventsource.html │ ├── _util_.httpresponse.html │ ├── _setup_.urbitconnection.html │ ├── _channel_.outstandingpoke.html │ └── _channel_.outstandingsubscription.html ├── index.html └── classes │ └── _channel_.channel.html ├── .gitignore ├── src ├── index.ts ├── marks.ts ├── util.ts ├── setup.ts └── channel.ts ├── tsconfig.json ├── package.json └── README.md /.nojekyll: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /docs/.nojekyll: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | node_modules 2 | lib/ 3 | *.d.ts 4 | *.js 5 | 6 | -------------------------------------------------------------------------------- /src/index.ts: -------------------------------------------------------------------------------- 1 | export * from './channel'; 2 | export * from './marks'; 3 | export * from './setup' 4 | -------------------------------------------------------------------------------- /docs/assets/images/icons.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/liam-fitzgerald/urbit-airlock-ts/HEAD/docs/assets/images/icons.png -------------------------------------------------------------------------------- /docs/assets/images/widgets.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/liam-fitzgerald/urbit-airlock-ts/HEAD/docs/assets/images/widgets.png -------------------------------------------------------------------------------- /docs/assets/images/icons@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/liam-fitzgerald/urbit-airlock-ts/HEAD/docs/assets/images/icons@2x.png -------------------------------------------------------------------------------- /docs/assets/images/widgets@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/liam-fitzgerald/urbit-airlock-ts/HEAD/docs/assets/images/widgets@2x.png -------------------------------------------------------------------------------- /src/marks.ts: -------------------------------------------------------------------------------- 1 | 2 | 3 | export interface Marks { 4 | readonly json: any; 5 | } 6 | 7 | export type Mark = keyof Marks; 8 | 9 | export interface Cage { 10 | mark: M; 11 | data: Marks[M]; 12 | } 13 | -------------------------------------------------------------------------------- /tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "include": ["src/**/*.ts"], 3 | "exclude": ["node_modules", "dist", "@types"], 4 | "compilerOptions": { 5 | "outDir": "./lib", 6 | "module": "commonjs", 7 | "noImplicitAny": true, 8 | "target": "es2015", 9 | "pretty": true, 10 | "moduleResolution": "node", 11 | "esModuleInterop": true, 12 | "allowSyntheticDefaultImports": true, 13 | "declaration": true 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /src/util.ts: -------------------------------------------------------------------------------- 1 | import * as http from "http"; 2 | export interface Config { 3 | port: number; 4 | delay: number; 5 | } 6 | interface HttpResponse { 7 | req: http.ClientRequest; 8 | res: http.IncomingMessage; 9 | data: string; 10 | } 11 | export function request( 12 | url: string, 13 | options: http.ClientRequestArgs, 14 | body?: string 15 | ) { 16 | return new Promise((resolve, reject) => { 17 | const req = http.request(url, options, res => { 18 | let data = ""; 19 | res.on("data", chunk => { 20 | data += chunk; 21 | }); 22 | res.on("end", () => { 23 | resolve({ req, res, data }); 24 | }); 25 | res.on("error", e => { 26 | reject(e); 27 | }); 28 | }); 29 | if (body) { 30 | req.write(body); 31 | } 32 | req.end(); 33 | }); 34 | } 35 | -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "urbit-airlock", 3 | "version": "0.0.2", 4 | "description": "A library for interacting with your urbit over HTTP", 5 | "files": [ 6 | "lib" 7 | ], 8 | "main": "lib/index.js", 9 | "typings": "lib/index.d.ts", 10 | "scripts": { 11 | "test": "echo \"Error: no test specified\" && exit 1", 12 | "build": "tsc", 13 | "watch": "tsc --watch", 14 | "clean": "rm -rf lib/*.d.ts lib/*.js", 15 | "docs": "typedoc --excludePrivate" 16 | }, 17 | "author": "", 18 | "license": "MIT", 19 | "dependencies": { 20 | "eventsource": "^1.0.7", 21 | "lodash": "^4.17.15", 22 | "react": "^16.13.1" 23 | }, 24 | "devDependencies": { 25 | "@types/eventsource": "^1.1.2", 26 | "@types/lodash": "^4.14.149", 27 | "@types/node": "^13.9.8", 28 | "@types/react": "^16.9.26", 29 | "typedoc": "^0.17.3", 30 | "typescript": "^3.8.3" 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /src/setup.ts: -------------------------------------------------------------------------------- 1 | import { request } from "./util"; 2 | import qs from "querystring"; 3 | 4 | /** 5 | * A description of an authenticated connection to an Urbit 6 | * 7 | */ 8 | export interface UrbitConnection { 9 | ship: string; 10 | cookies: string; 11 | url: string; 12 | port: number; 13 | } 14 | 15 | /** 16 | * Authenticate to an Urbit over HTTP. 17 | * @param ship @p of the running Urbit, without leading sig 18 | * @param url URL of the running Urbit 19 | * @param port HTTP Port of the running Urbit 20 | * @param password +code from the running Urbit 21 | */ 22 | export async function connect( 23 | ship: string, 24 | url: string, 25 | port: number, 26 | password: string 27 | ): Promise { 28 | const { res } = await request( 29 | url + "/~/login", 30 | { method: "post", port }, 31 | qs.stringify({ password }) 32 | ); 33 | 34 | if (!res.headers["set-cookie"]) { 35 | throw new Error("Unable to connect to Urbit"); 36 | } 37 | 38 | const cookies = res.headers["set-cookie"][0] || ""; 39 | return { cookies, ship, url, port }; 40 | } 41 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Urbit Airlock bindings 2 | 3 | ## Installation 4 | 5 | `npm install urbit-airlock --save` 6 | 7 | ## Usage 8 | 9 | ### Connection 10 | 11 | Opening a connection to your urbit is as follows 12 | 13 | ``` typescript 14 | const connection = await connect( 15 | 'zod', 16 | 'http://localhost', 17 | 80, 18 | 'lidlut-tabwed-pillex-ridrup' 19 | ); 20 | const channel = new Channel(connection); 21 | 22 | ``` 23 | 24 | You may then subscribe and poke over the connection. 25 | 26 | ```typescript 27 | 28 | 29 | channel.subscribe('chat-view', '/primary', { 30 | mark: 'json', 31 | onError: (err: any) => { console.log(err); }, 32 | onEvent: (event: any) => { console.log(event); }, 33 | onQuit: (err: any) => { console.log(err); } 34 | }); 35 | 36 | channel.poke('gall-app', { 37 | mark: 'json', 38 | data: { update: 2 } 39 | }); 40 | ``` 41 | 42 | ### Typescript 43 | 44 | Pokes and subscription updates are strongly typed, but you need to make the 45 | interface-mark correspondence known to typescript. 46 | 47 | You associate a mark to an interface like so 48 | 49 | ``` typescript 50 | declare module 'urbit-airlock/lib/marks' { 51 | interface Marks { 52 | readonly 'number': number; 53 | } 54 | } 55 | ``` 56 | 57 | This associates the 'number' mark to the typescript type `number` 58 | 59 | -------------------------------------------------------------------------------- /docs/globals.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | urbit-airlock 7 | 8 | 9 | 10 | 11 | 12 |
13 |
14 |
15 |
16 | 27 |
28 |
29 | Options 30 |
31 |
32 | All 33 |
    34 |
  • Public
  • 35 |
  • Public/Protected
  • 36 |
  • All
  • 37 |
38 |
39 | 40 | 41 | 42 | 43 | 44 | 45 |
46 |
47 | Menu 48 |
49 |
50 |
51 |
52 |
53 |
54 | 59 |

urbit-airlock

60 |
61 |
62 |
63 |
64 |
65 |
66 |
67 |

Index

68 |
69 |
70 |
71 |

Modules

72 | 79 |
80 |
81 |
82 |
83 |
84 | 112 |
113 |
114 |
115 |
116 |

Legend

117 |
118 |
    119 |
  • Function
  • 120 |
  • Type alias
  • 121 |
  • Type alias with type parameter
  • 122 |
123 |
    124 |
  • Interface
  • 125 |
  • Interface with type parameter
  • 126 |
127 |
    128 |
  • Class
  • 129 |
130 |
131 |
132 |
133 |
134 |

Generated using TypeDoc

135 |
136 |
137 | 138 | 139 | 140 | -------------------------------------------------------------------------------- /docs/modules/_marks_.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | "marks" | urbit-airlock 7 | 8 | 9 | 10 | 11 | 12 |
13 |
14 |
15 |
16 | 27 |
28 |
29 | Options 30 |
31 |
32 | All 33 |
    34 |
  • Public
  • 35 |
  • Public/Protected
  • 36 |
  • All
  • 37 |
38 |
39 | 40 | 41 | 42 | 43 | 44 | 45 |
46 |
47 | Menu 48 |
49 |
50 |
51 |
52 |
53 |
54 | 62 |

Module "marks"

63 |
64 |
65 |
66 |
67 |
68 |
69 |
70 |

Index

71 |
72 |
73 |
74 |

Interfaces

75 | 79 |
80 |
81 |

Type aliases

82 | 85 |
86 |
87 |
88 |
89 |
90 |

Type aliases

91 |
92 | 93 |

Mark

94 |
Mark: keyof Marks
95 | 100 |
101 |
102 |
103 | 140 |
141 |
142 |
143 |
144 |

Legend

145 |
146 |
    147 |
  • Function
  • 148 |
  • Type alias
  • 149 |
  • Type alias with type parameter
  • 150 |
151 |
    152 |
  • Interface
  • 153 |
  • Interface with type parameter
  • 154 |
155 |
    156 |
  • Class
  • 157 |
158 |
159 |
160 |
161 |
162 |

Generated using TypeDoc

163 |
164 |
165 | 166 | 167 | 168 | -------------------------------------------------------------------------------- /docs/interfaces/_marks_.marks.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | Marks | urbit-airlock 7 | 8 | 9 | 10 | 11 | 12 |
13 |
14 |
15 |
16 | 27 |
28 |
29 | Options 30 |
31 |
32 | All 33 |
    34 |
  • Public
  • 35 |
  • Public/Protected
  • 36 |
  • All
  • 37 |
38 |
39 | 40 | 41 | 42 | 43 | 44 | 45 |
46 |
47 | Menu 48 |
49 |
50 |
51 |
52 |
53 |
54 | 65 |

Interface Marks

66 |
67 |
68 |
69 |
70 |
71 |
72 |
73 |

Hierarchy

74 |
    75 |
  • 76 | Marks 77 |
  • 78 |
79 |
80 |
81 |

Index

82 |
83 |
84 |
85 |

Properties

86 | 89 |
90 |
91 |
92 |
93 |
94 |

Properties

95 |
96 | 97 |

json

98 |
json: any
99 | 104 |
105 |
106 |
107 | 153 |
154 |
155 |
156 |
157 |

Legend

158 |
159 |
    160 |
  • Function
  • 161 |
  • Type alias
  • 162 |
  • Type alias with type parameter
  • 163 |
164 |
    165 |
  • Interface
  • 166 |
  • Interface with type parameter
  • 167 |
  • Property
  • 168 |
169 |
    170 |
  • Class
  • 171 |
172 |
173 |
174 |
175 |
176 |

Generated using TypeDoc

177 |
178 |
179 | 180 | 181 | 182 | -------------------------------------------------------------------------------- /src/channel.ts: -------------------------------------------------------------------------------- 1 | import { request, Config } from "./util"; 2 | import EventSource from "eventsource"; 3 | import { Marks, Mark, Cage } from "./marks"; 4 | import { UrbitConnection } from "./setup"; 5 | 6 | interface OutstandingPoke { 7 | onSuccess: () => void; 8 | onFailure: (e: any) => void; 9 | } 10 | 11 | interface SubscriptionEventSource { 12 | application: string; 13 | ship: string; 14 | } 15 | 16 | type SubscriptionEvent = SubscriptionEventSource & Cage; 17 | 18 | export interface OutstandingSubscription { 19 | mark: M; 20 | onError: (err: any) => void; 21 | onEvent: (event: Cage) => void; 22 | onQuit: (err: any) => void; 23 | } 24 | 25 | /** 26 | * A Channel is an HTTP connection to a running Urbit. Using it, you can poke and subscribe to agents 27 | */ 28 | export class Channel { 29 | /** 30 | * unique identifier: current time and random number 31 | */ 32 | 33 | private uid: string = 34 | new Date().getTime().toString() + 35 | "-" + 36 | Math.random() 37 | .toString(16) 38 | .slice(-6); 39 | /** 40 | * The ID of the last request we sent to the server 41 | */ 42 | private requestId: number = 1; 43 | 44 | /** 45 | * The EventSource that we are receiving messages on, 46 | * or null if we've not connected yet. 47 | */ 48 | private eventSource: EventSource | null = null; 49 | 50 | /** 51 | * The id of the last EventSource event we received 52 | */ 53 | private lastEventId: number = 0; 54 | 55 | /** 56 | * The id of the last event we acked to the server 57 | */ 58 | private lastAcknowledgedEventId: number = 0; 59 | 60 | /** 61 | * A map of requestId to handlers 62 | * 63 | * These functions are registered during a +poke and are executed 64 | * in the onServerEvent()/onServerError() callbacks. Only one of 65 | * the functions will be called, and the outstanding poke will be 66 | * removed after calling the success or failure function. 67 | */ 68 | private outstandingPokes: Map = new Map(); 69 | 70 | /** 71 | * A map of requestId to subscription handlers. 72 | * 73 | * These functions are registered during a +subscribe and are 74 | * executed in the onServerEvent()/onServerError() callbacks. The 75 | * event function will be called whenever a new piece of data on this 76 | * subscription is available, which may be 0, 1, or many times. The 77 | * disconnect function may be called exactly once. 78 | */ 79 | private outstandingSubscriptions: Map< 80 | number, 81 | OutstandingSubscription 82 | > = new Map(); 83 | 84 | /** 85 | * @param conn Object describing connection to urbit 86 | */ 87 | constructor(private conn: UrbitConnection) {} 88 | 89 | /** 90 | * Poke a Gall agent with a cage. 91 | * @param app name of Gall agent to send poke to 92 | * @param cage The cage to poke the agent with 93 | * @returns A promise that resolves when the poke is successfully 94 | * executed and rejects when the poke errors 95 | */ 96 | poke(app: string, cage: Cage): Promise { 97 | let id = this.nextId(); 98 | return new Promise((resolve, reject) => { 99 | this.outstandingPokes.set(id, { onSuccess: resolve, onFailure: reject }); 100 | 101 | this.sendJSONToChannel({ 102 | id, 103 | action: "poke", 104 | ship: this.conn.ship, 105 | app, 106 | mark: cage.mark, 107 | json: cage.data 108 | }); 109 | }); 110 | } 111 | 112 | /** 113 | * Subscribe to a Gall agent on a path, executing handlers on each event or on subscription quit or subscription error. 114 | * See also: [[unsubscribe]] 115 | * 116 | * @param app name of Gall agent to subscribe to 117 | * @param path path to subscribe on 118 | * @param handlers event handlers for the subscription 119 | * @returns a subscription id, which can be used to cancel the subscription 120 | */ 121 | subscribe( 122 | app: string, 123 | path: string, 124 | handlers: OutstandingSubscription 125 | ): number { 126 | let id = this.nextId(); 127 | this.outstandingSubscriptions.set(id, handlers); 128 | 129 | this.sendJSONToChannel({ 130 | id, 131 | action: "subscribe", 132 | ship: this.conn.ship, 133 | app, 134 | path 135 | }); 136 | 137 | return id; 138 | } 139 | 140 | /** 141 | * Cancel a subscription to a gall agent 142 | * 143 | * @param subscription the ID returned from [[subscribe]] 144 | */ 145 | unsubscribe(subscription: number) { 146 | let id = this.nextId(); 147 | this.sendJSONToChannel({ 148 | id, 149 | action: "unsubscribe", 150 | subscription 151 | }); 152 | } 153 | 154 | // sends a JSON command command to the server. 155 | // 156 | private sendJSONToChannel(j: unknown) { 157 | let body: any; 158 | if (this.lastEventId == this.lastAcknowledgedEventId) { 159 | body = JSON.stringify([j]); 160 | } else { 161 | // we add an acknowledgment to clear the server side queue 162 | // 163 | // The server side puts messages it sends us in a queue until we 164 | // acknowledge that we received it. 165 | // 166 | body = JSON.stringify([ 167 | { action: "ack", "event-id": this.lastEventId }, 168 | j 169 | ]); 170 | 171 | this.lastEventId = this.lastAcknowledgedEventId; 172 | } 173 | return request( 174 | this.channelURL(), 175 | { 176 | method: "PUT", 177 | headers: { 178 | "Content-Type": "application/json", 179 | "Content-Length": body.length, 180 | Cookie: this.conn.cookies 181 | }, 182 | port: this.conn.port 183 | }, 184 | body 185 | ).then(r => { 186 | return this.connectIfDisconnected(); 187 | }); 188 | } 189 | 190 | // connects to the EventSource if we are not currently connected 191 | // 192 | private connectIfDisconnected() { 193 | if (this.eventSource) { 194 | return; 195 | } 196 | 197 | const eventSource = new EventSource(this.channelURL(), { 198 | headers: { Cookie: this.conn.cookies, Connection: "keep-alive" }, 199 | withCredentials: true 200 | }); 201 | eventSource.onmessage = (e: MessageEvent) => { 202 | this.lastEventId = parseInt(e.lastEventId, 10); 203 | 204 | let obj = JSON.parse(e.data); 205 | if (obj.response == "poke") { 206 | let funcs = this.outstandingPokes.get(obj.id); 207 | if (obj.hasOwnProperty("ok")) { 208 | funcs.onSuccess(); 209 | } else if (obj.hasOwnProperty("err") && funcs) { 210 | funcs.onFailure(obj.err); 211 | } 212 | this.outstandingPokes.delete(obj.id); 213 | } else if (obj.response == "subscribe") { 214 | // on a response to a subscribe, we only notify the caller on err 215 | // 216 | let funcs = this.outstandingSubscriptions.get(obj.id); 217 | if (obj.hasOwnProperty("err")) { 218 | funcs.onError(obj.err); 219 | this.outstandingSubscriptions.delete(obj.id); 220 | } 221 | } else if (obj.response == "diff") { 222 | let funcs = this.outstandingSubscriptions.get(obj.id); 223 | funcs.onEvent(obj.json); 224 | } else if (obj.response == "quit") { 225 | let funcs = this.outstandingSubscriptions.get(obj.id); 226 | funcs.onQuit(obj); 227 | this.outstandingSubscriptions.delete(obj.id); 228 | } else { 229 | } 230 | }; 231 | 232 | eventSource.onerror = e => {}; 233 | this.eventSource = eventSource; 234 | } 235 | 236 | private channelURL() { 237 | const result = 238 | this.conn.url + ":" + this.conn.port + "/~/channel/" + this.uid; 239 | return result; 240 | } 241 | 242 | private nextId() { 243 | return this.requestId++; 244 | } 245 | } 246 | -------------------------------------------------------------------------------- /docs/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | urbit-airlock 7 | 8 | 9 | 10 | 11 | 12 |
13 |
14 |
15 |
16 | 27 |
28 |
29 | Options 30 |
31 |
32 | All 33 |
    34 |
  • Public
  • 35 |
  • Public/Protected
  • 36 |
  • All
  • 37 |
38 |
39 | 40 | 41 | 42 | 43 | 44 | 45 |
46 |
47 | Menu 48 |
49 |
50 |
51 |
52 |
53 |
54 | 59 |

urbit-airlock

60 |
61 |
62 |
63 |
64 |
65 |
66 |
67 | 68 |

Urbit Airlock bindings

69 |
70 | 71 |

Installation

72 |
73 |

npm install urbit-airlock --save

74 | 75 |

Usage

76 |
77 | 78 |

Connection

79 |
80 |

Opening a connection to your urbit is as follows

81 |
const connection = await connect(
 82 |   'zod',
 83 |   'http://localhost',
 84 |   80,
 85 |   'lidlut-tabwed-pillex-ridrup'
 86 | );
 87 | const channel = new Channel(connection);
 88 | 
89 |

You may then subscribe and poke over the connection.

90 |

 91 | 
 92 | channel.subscribe('chat-view', '/primary', {
 93 |   mark: 'json',
 94 |   onError: (err: any) => { console.log(err); },
 95 |   onEvent: (event: any) => { console.log(event); },
 96 |   onQuit: (err: any) => { console.log(err); }
 97 | });
 98 | 
 99 | channel.poke('gall-app', {
100 |   mark: 'json',
101 |   data: { update: 2 }
102 | });
103 | 104 |

Typescript

105 |
106 |

Pokes and subscription updates are strongly typed, but you need to make the 107 | interface-mark correspondence known to typescript.

108 |

You associate a mark to an interface like so

109 |
declare module 'urbit-airlock/lib/marks' {
110 |   interface Marks {
111 |     readonly 'number': number;
112 |   }
113 | }
114 |

This associates the 'number' mark to the typescript type number

115 |
116 |
117 | 145 |
146 |
147 |
148 |
149 |

Legend

150 |
151 |
    152 |
  • Function
  • 153 |
  • Type alias
  • 154 |
  • Type alias with type parameter
  • 155 |
156 |
    157 |
  • Interface
  • 158 |
  • Interface with type parameter
  • 159 |
160 |
    161 |
  • Class
  • 162 |
163 |
164 |
165 |
166 |
167 |

Generated using TypeDoc

168 |
169 |
170 | 171 | 172 | 173 | -------------------------------------------------------------------------------- /docs/interfaces/_util_.config.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | Config | urbit-airlock 7 | 8 | 9 | 10 | 11 | 12 |
13 |
14 |
15 |
16 | 27 |
28 |
29 | Options 30 |
31 |
32 | All 33 |
    34 |
  • Public
  • 35 |
  • Public/Protected
  • 36 |
  • All
  • 37 |
38 |
39 | 40 | 41 | 42 | 43 | 44 | 45 |
46 |
47 | Menu 48 |
49 |
50 |
51 |
52 |
53 |
54 | 65 |

Interface Config

66 |
67 |
68 |
69 |
70 |
71 |
72 |
73 |

Hierarchy

74 |
    75 |
  • 76 | Config 77 |
  • 78 |
79 |
80 |
81 |

Index

82 |
83 |
84 |
85 |

Properties

86 | 90 |
91 |
92 |
93 |
94 |
95 |

Properties

96 |
97 | 98 |

delay

99 |
delay: number
100 | 105 |
106 |
107 | 108 |

port

109 |
port: number
110 | 115 |
116 |
117 |
118 | 167 |
168 |
169 |
170 |
171 |

Legend

172 |
173 |
    174 |
  • Function
  • 175 |
  • Type alias
  • 176 |
  • Type alias with type parameter
  • 177 |
178 |
    179 |
  • Interface
  • 180 |
  • Interface with type parameter
  • 181 |
  • Property
  • 182 |
183 |
    184 |
  • Class
  • 185 |
186 |
187 |
188 |
189 |
190 |

Generated using TypeDoc

191 |
192 |
193 | 194 | 195 | 196 | -------------------------------------------------------------------------------- /docs/interfaces/_marks_.cage.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | Cage | urbit-airlock 7 | 8 | 9 | 10 | 11 | 12 |
13 |
14 |
15 |
16 | 27 |
28 |
29 | Options 30 |
31 |
32 | All 33 |
    34 |
  • Public
  • 35 |
  • Public/Protected
  • 36 |
  • All
  • 37 |
38 |
39 | 40 | 41 | 42 | 43 | 44 | 45 |
46 |
47 | Menu 48 |
49 |
50 |
51 |
52 |
53 |
54 | 65 |

Interface Cage<M>

66 |
67 |
68 |
69 |
70 |
71 |
72 |
73 |

Type parameters

74 |
    75 |
  • 76 |

    M: Mark

    77 |
  • 78 |
79 |
80 |
81 |

Hierarchy

82 |
    83 |
  • 84 | Cage 85 |
  • 86 |
87 |
88 |
89 |

Index

90 |
91 |
92 |
93 |

Properties

94 | 98 |
99 |
100 |
101 |
102 |
103 |

Properties

104 |
105 | 106 |

data

107 |
data: Marks[M]
108 | 113 |
114 |
115 | 116 |

mark

117 |
mark: M
118 | 123 |
124 |
125 |
126 | 175 |
176 |
177 |
178 |
179 |

Legend

180 |
181 |
    182 |
  • Function
  • 183 |
  • Type alias
  • 184 |
  • Type alias with type parameter
  • 185 |
186 |
    187 |
  • Interface
  • 188 |
  • Interface with type parameter
  • 189 |
  • Property
  • 190 |
191 |
    192 |
  • Class
  • 193 |
194 |
195 |
196 |
197 |
198 |

Generated using TypeDoc

199 |
200 |
201 | 202 | 203 | 204 | -------------------------------------------------------------------------------- /docs/modules/_util_.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | "util" | urbit-airlock 7 | 8 | 9 | 10 | 11 | 12 |
13 |
14 |
15 |
16 | 27 |
28 |
29 | Options 30 |
31 |
32 | All 33 |
    34 |
  • Public
  • 35 |
  • Public/Protected
  • 36 |
  • All
  • 37 |
38 |
39 | 40 | 41 | 42 | 43 | 44 | 45 |
46 |
47 | Menu 48 |
49 |
50 |
51 |
52 |
53 |
54 | 62 |

Module "util"

63 |
64 |
65 |
66 |
67 |
68 |
69 |
70 |

Index

71 |
72 |
73 |
74 |

Interfaces

75 | 79 |
80 |
81 |

Functions

82 | 85 |
86 |
87 |
88 |
89 |
90 |

Functions

91 |
92 | 93 |

request

94 |
    95 |
  • request(url: string, options: ClientRequestArgs, body?: string): Promise<HttpResponse>
  • 96 |
97 |
    98 |
  • 99 | 104 |

    Parameters

    105 |
      106 |
    • 107 |
      url: string
      108 |
    • 109 |
    • 110 |
      options: ClientRequestArgs
      111 |
    • 112 |
    • 113 |
      Optional body: string
      114 |
    • 115 |
    116 |

    Returns Promise<HttpResponse>

    117 |
  • 118 |
119 |
120 |
121 |
122 | 159 |
160 |
161 |
162 |
163 |

Legend

164 |
165 |
    166 |
  • Function
  • 167 |
  • Type alias
  • 168 |
  • Type alias with type parameter
  • 169 |
170 |
    171 |
  • Interface
  • 172 |
  • Interface with type parameter
  • 173 |
174 |
    175 |
  • Class
  • 176 |
177 |
178 |
179 |
180 |
181 |

Generated using TypeDoc

182 |
183 |
184 | 185 | 186 | 187 | -------------------------------------------------------------------------------- /docs/modules/_channel_.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | "channel" | urbit-airlock 7 | 8 | 9 | 10 | 11 | 12 |
13 |
14 |
15 |
16 | 27 |
28 |
29 | Options 30 |
31 |
32 | All 33 |
    34 |
  • Public
  • 35 |
  • Public/Protected
  • 36 |
  • All
  • 37 |
38 |
39 | 40 | 41 | 42 | 43 | 44 | 45 |
46 |
47 | Menu 48 |
49 |
50 |
51 |
52 |
53 |
54 | 62 |

Module "channel"

63 |
64 |
65 |
66 |
67 |
68 |
69 |
70 |

Index

71 |
72 |
73 |
74 |

Classes

75 | 78 |
79 |
80 |

Interfaces

81 | 86 |
87 |
88 |

Type aliases

89 | 92 |
93 |
94 |
95 |
96 |
97 |

Type aliases

98 |
99 | 100 |

SubscriptionEvent

101 |
SubscriptionEvent<M>: SubscriptionEventSource & Cage<M>
102 | 107 |

Type parameters

108 |
    109 |
  • 110 |

    M: Mark

    111 |
  • 112 |
113 |
114 |
115 |
116 | 159 |
160 |
161 |
162 |
163 |

Legend

164 |
165 |
    166 |
  • Function
  • 167 |
  • Type alias
  • 168 |
  • Type alias with type parameter
  • 169 |
170 |
    171 |
  • Interface
  • 172 |
  • Interface with type parameter
  • 173 |
174 |
    175 |
  • Class
  • 176 |
177 |
178 |
179 |
180 |
181 |

Generated using TypeDoc

182 |
183 |
184 | 185 | 186 | 187 | -------------------------------------------------------------------------------- /docs/interfaces/_channel_.subscriptioneventsource.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | SubscriptionEventSource | urbit-airlock 7 | 8 | 9 | 10 | 11 | 12 |
13 |
14 |
15 |
16 | 27 |
28 |
29 | Options 30 |
31 |
32 | All 33 |
    34 |
  • Public
  • 35 |
  • Public/Protected
  • 36 |
  • All
  • 37 |
38 |
39 | 40 | 41 | 42 | 43 | 44 | 45 |
46 |
47 | Menu 48 |
49 |
50 |
51 |
52 |
53 |
54 | 65 |

Interface SubscriptionEventSource

66 |
67 |
68 |
69 |
70 |
71 |
72 |
73 |

Hierarchy

74 |
    75 |
  • 76 | SubscriptionEventSource 77 |
  • 78 |
79 |
80 |
81 |

Index

82 |
83 |
84 |
85 |

Properties

86 | 90 |
91 |
92 |
93 |
94 |
95 |

Properties

96 |
97 | 98 |

application

99 |
application: string
100 | 105 |
106 |
107 | 108 |

ship

109 |
ship: string
110 | 115 |
116 |
117 |
118 | 173 |
174 |
175 |
176 |
177 |

Legend

178 |
179 |
    180 |
  • Function
  • 181 |
  • Type alias
  • 182 |
  • Type alias with type parameter
  • 183 |
184 |
    185 |
  • Interface
  • 186 |
  • Interface with type parameter
  • 187 |
  • Property
  • 188 |
189 |
    190 |
  • Class
  • 191 |
192 |
193 |
194 |
195 |
196 |

Generated using TypeDoc

197 |
198 |
199 | 200 | 201 | 202 | -------------------------------------------------------------------------------- /docs/modules/_setup_.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | "setup" | urbit-airlock 7 | 8 | 9 | 10 | 11 | 12 |
13 |
14 |
15 |
16 | 27 |
28 |
29 | Options 30 |
31 |
32 | All 33 |
    34 |
  • Public
  • 35 |
  • Public/Protected
  • 36 |
  • All
  • 37 |
38 |
39 | 40 | 41 | 42 | 43 | 44 | 45 |
46 |
47 | Menu 48 |
49 |
50 |
51 |
52 |
53 |
54 | 62 |

Module "setup"

63 |
64 |
65 |
66 |
67 |
68 |
69 |
70 |

Index

71 |
72 |
73 |
74 |

Interfaces

75 | 78 |
79 |
80 |

Functions

81 | 84 |
85 |
86 |
87 |
88 |
89 |

Functions

90 |
91 | 92 |

connect

93 |
    94 |
  • connect(ship: string, url: string, port: number, password: string): Promise<UrbitConnection>
  • 95 |
96 |
    97 |
  • 98 | 103 |
    104 |
    105 |

    Authenticate to an Urbit over HTTP.

    106 |
    107 |
    108 |

    Parameters

    109 |
      110 |
    • 111 |
      ship: string
      112 |
      113 |

      @p of the running Urbit, without leading sig

      114 |
      115 |
    • 116 |
    • 117 |
      url: string
      118 |
      119 |

      URL of the running Urbit

      120 |
      121 |
    • 122 |
    • 123 |
      port: number
      124 |
      125 |

      HTTP Port of the running Urbit

      126 |
      127 |
    • 128 |
    • 129 |
      password: string
      130 |
      131 |

      +code from the running Urbit

      132 |
      133 |
    • 134 |
    135 |

    Returns Promise<UrbitConnection>

    136 |
  • 137 |
138 |
139 |
140 |
141 | 175 |
176 |
177 |
178 |
179 |

Legend

180 |
181 |
    182 |
  • Function
  • 183 |
  • Type alias
  • 184 |
  • Type alias with type parameter
  • 185 |
186 |
    187 |
  • Interface
  • 188 |
  • Interface with type parameter
  • 189 |
190 |
    191 |
  • Class
  • 192 |
193 |
194 |
195 |
196 |
197 |

Generated using TypeDoc

198 |
199 |
200 | 201 | 202 | 203 | -------------------------------------------------------------------------------- /docs/interfaces/_util_.httpresponse.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | HttpResponse | urbit-airlock 7 | 8 | 9 | 10 | 11 | 12 |
13 |
14 |
15 |
16 | 27 |
28 |
29 | Options 30 |
31 |
32 | All 33 |
    34 |
  • Public
  • 35 |
  • Public/Protected
  • 36 |
  • All
  • 37 |
38 |
39 | 40 | 41 | 42 | 43 | 44 | 45 |
46 |
47 | Menu 48 |
49 |
50 |
51 |
52 |
53 |
54 | 65 |

Interface HttpResponse

66 |
67 |
68 |
69 |
70 |
71 |
72 |
73 |

Hierarchy

74 |
    75 |
  • 76 | HttpResponse 77 |
  • 78 |
79 |
80 |
81 |

Index

82 |
83 |
84 |
85 |

Properties

86 | 91 |
92 |
93 |
94 |
95 |
96 |

Properties

97 |
98 | 99 |

data

100 |
data: string
101 | 106 |
107 |
108 | 109 |

req

110 |
req: ClientRequest
111 | 116 |
117 |
118 | 119 |

res

120 |
res: IncomingMessage
121 | 126 |
127 |
128 |
129 | 181 |
182 |
183 |
184 |
185 |

Legend

186 |
187 |
    188 |
  • Function
  • 189 |
  • Type alias
  • 190 |
  • Type alias with type parameter
  • 191 |
192 |
    193 |
  • Interface
  • 194 |
  • Interface with type parameter
  • 195 |
  • Property
  • 196 |
197 |
    198 |
  • Class
  • 199 |
200 |
201 |
202 |
203 |
204 |

Generated using TypeDoc

205 |
206 |
207 | 208 | 209 | 210 | -------------------------------------------------------------------------------- /docs/modules/_index_.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | "index" | urbit-airlock 7 | 8 | 9 | 10 | 11 | 12 |
13 |
14 |
15 |
16 | 27 |
28 |
29 | Options 30 |
31 |
32 | All 33 |
    34 |
  • Public
  • 35 |
  • Public/Protected
  • 36 |
  • All
  • 37 |
38 |
39 | 40 | 41 | 42 | 43 | 44 | 45 |
46 |
47 | Menu 48 |
49 |
50 |
51 |
52 |
53 |
54 | 62 |

Module "index"

63 |
64 |
65 |
66 |
67 |
68 |
69 |
70 |

Index

71 |
72 |
73 |
74 |

References

75 | 84 |
85 |
86 |
87 |
88 |
89 |

References

90 |
91 | 92 |

Cage

93 | Re-exports Cage 94 |
95 |
96 | 97 |

Channel

98 | Re-exports Channel 99 |
100 |
101 | 102 |

Mark

103 | Re-exports Mark 104 |
105 |
106 | 107 |

Marks

108 | Re-exports Marks 109 |
110 |
111 | 112 |

OutstandingSubscription

113 | Re-exports OutstandingSubscription 114 |
115 |
116 | 117 |

UrbitConnection

118 | Re-exports UrbitConnection 119 |
120 |
121 | 122 |

connect

123 | Re-exports connect 124 |
125 |
126 |
127 | 176 |
177 |
178 |
179 |
180 |

Legend

181 |
182 |
    183 |
  • Function
  • 184 |
  • Type alias
  • 185 |
  • Type alias with type parameter
  • 186 |
187 |
    188 |
  • Interface
  • 189 |
  • Interface with type parameter
  • 190 |
191 |
    192 |
  • Class
  • 193 |
194 |
195 |
196 |
197 |
198 |

Generated using TypeDoc

199 |
200 |
201 | 202 | 203 | 204 | -------------------------------------------------------------------------------- /docs/interfaces/_setup_.urbitconnection.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | UrbitConnection | urbit-airlock 7 | 8 | 9 | 10 | 11 | 12 |
13 |
14 |
15 |
16 | 27 |
28 |
29 | Options 30 |
31 |
32 | All 33 |
    34 |
  • Public
  • 35 |
  • Public/Protected
  • 36 |
  • All
  • 37 |
38 |
39 | 40 | 41 | 42 | 43 | 44 | 45 |
46 |
47 | Menu 48 |
49 |
50 |
51 |
52 |
53 |
54 | 65 |

Interface UrbitConnection

66 |
67 |
68 |
69 |
70 |
71 |
72 |
73 |
74 |
75 |

A description of an authenticated connection to an Urbit

76 |
77 |
78 |
79 |
80 |

Hierarchy

81 |
    82 |
  • 83 | UrbitConnection 84 |
  • 85 |
86 |
87 |
88 |

Index

89 |
90 |
91 |
92 |

Properties

93 | 99 |
100 |
101 |
102 |
103 |
104 |

Properties

105 |
106 | 107 |

cookies

108 |
cookies: string
109 | 114 |
115 |
116 | 117 |

port

118 |
port: number
119 | 124 |
125 |
126 | 127 |

ship

128 |
ship: string
129 | 134 |
135 |
136 | 137 |

url

138 |
url: string
139 | 144 |
145 |
146 |
147 | 199 |
200 |
201 |
202 |
203 |

Legend

204 |
205 |
    206 |
  • Function
  • 207 |
  • Type alias
  • 208 |
  • Type alias with type parameter
  • 209 |
210 |
    211 |
  • Interface
  • 212 |
  • Interface with type parameter
  • 213 |
  • Property
  • 214 |
215 |
    216 |
  • Class
  • 217 |
218 |
219 |
220 |
221 |
222 |

Generated using TypeDoc

223 |
224 |
225 | 226 | 227 | 228 | -------------------------------------------------------------------------------- /docs/interfaces/_channel_.outstandingpoke.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | OutstandingPoke | urbit-airlock 7 | 8 | 9 | 10 | 11 | 12 |
13 |
14 |
15 |
16 | 27 |
28 |
29 | Options 30 |
31 |
32 | All 33 |
    34 |
  • Public
  • 35 |
  • Public/Protected
  • 36 |
  • All
  • 37 |
38 |
39 | 40 | 41 | 42 | 43 | 44 | 45 |
46 |
47 | Menu 48 |
49 |
50 |
51 |
52 |
53 |
54 | 65 |

Interface OutstandingPoke

66 |
67 |
68 |
69 |
70 |
71 |
72 |
73 |

Hierarchy

74 |
    75 |
  • 76 | OutstandingPoke 77 |
  • 78 |
79 |
80 |
81 |

Index

82 |
83 |
84 |
85 |

Properties

86 | 90 |
91 |
92 |
93 |
94 |
95 |

Properties

96 |
97 | 98 |

onFailure

99 |
onFailure: (e: any) => void
100 | 105 |
106 |

Type declaration

107 |
    108 |
  • 109 |
      110 |
    • (e: any): void
    • 111 |
    112 |
      113 |
    • 114 |

      Parameters

      115 |
        116 |
      • 117 |
        e: any
        118 |
      • 119 |
      120 |

      Returns void

      121 |
    • 122 |
    123 |
  • 124 |
125 |
126 |
127 |
128 | 129 |

onSuccess

130 |
onSuccess: () => void
131 | 136 |
137 |

Type declaration

138 |
    139 |
  • 140 |
      141 |
    • (): void
    • 142 |
    143 |
      144 |
    • 145 |

      Returns void

      146 |
    • 147 |
    148 |
  • 149 |
150 |
151 |
152 |
153 |
154 | 209 |
210 |
211 |
212 |
213 |

Legend

214 |
215 |
    216 |
  • Function
  • 217 |
  • Type alias
  • 218 |
  • Type alias with type parameter
  • 219 |
220 |
    221 |
  • Interface
  • 222 |
  • Interface with type parameter
  • 223 |
  • Property
  • 224 |
225 |
    226 |
  • Class
  • 227 |
228 |
229 |
230 |
231 |
232 |

Generated using TypeDoc

233 |
234 |
235 | 236 | 237 | 238 | -------------------------------------------------------------------------------- /docs/interfaces/_channel_.outstandingsubscription.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | OutstandingSubscription | urbit-airlock 7 | 8 | 9 | 10 | 11 | 12 |
13 |
14 |
15 |
16 | 27 |
28 |
29 | Options 30 |
31 |
32 | All 33 |
    34 |
  • Public
  • 35 |
  • Public/Protected
  • 36 |
  • All
  • 37 |
38 |
39 | 40 | 41 | 42 | 43 | 44 | 45 |
46 |
47 | Menu 48 |
49 |
50 |
51 |
52 |
53 |
54 | 65 |

Interface OutstandingSubscription<M>

66 |
67 |
68 |
69 |
70 |
71 |
72 |
73 |

Type parameters

74 |
    75 |
  • 76 |

    M: Mark

    77 |
  • 78 |
79 |
80 |
81 |

Hierarchy

82 |
    83 |
  • 84 | OutstandingSubscription 85 |
  • 86 |
87 |
88 |
89 |

Index

90 |
91 |
92 |
93 |

Properties

94 | 100 |
101 |
102 |
103 |
104 |
105 |

Properties

106 |
107 | 108 |

mark

109 |
mark: M
110 | 115 |
116 |
117 | 118 |

onError

119 |
onError: (err: any) => void
120 | 125 |
126 |

Type declaration

127 |
    128 |
  • 129 |
      130 |
    • (err: any): void
    • 131 |
    132 |
      133 |
    • 134 |

      Parameters

      135 |
        136 |
      • 137 |
        err: any
        138 |
      • 139 |
      140 |

      Returns void

      141 |
    • 142 |
    143 |
  • 144 |
145 |
146 |
147 |
148 | 149 |

onEvent

150 |
onEvent: (event: Cage<M>) => void
151 | 156 |
157 |

Type declaration

158 |
    159 |
  • 160 |
      161 |
    • (event: Cage<M>): void
    • 162 |
    163 |
      164 |
    • 165 |

      Parameters

      166 |
        167 |
      • 168 |
        event: Cage<M>
        169 |
      • 170 |
      171 |

      Returns void

      172 |
    • 173 |
    174 |
  • 175 |
176 |
177 |
178 |
179 | 180 |

onQuit

181 |
onQuit: (err: any) => void
182 | 187 |
188 |

Type declaration

189 |
    190 |
  • 191 |
      192 |
    • (err: any): void
    • 193 |
    194 |
      195 |
    • 196 |

      Parameters

      197 |
        198 |
      • 199 |
        err: any
        200 |
      • 201 |
      202 |

      Returns void

      203 |
    • 204 |
    205 |
  • 206 |
207 |
208 |
209 |
210 |
211 | 272 |
273 |
274 |
275 |
276 |

Legend

277 |
278 |
    279 |
  • Function
  • 280 |
  • Type alias
  • 281 |
  • Type alias with type parameter
  • 282 |
283 |
    284 |
  • Interface
  • 285 |
  • Interface with type parameter
  • 286 |
  • Property
  • 287 |
288 |
    289 |
  • Class
  • 290 |
291 |
292 |
293 |
294 |
295 |

Generated using TypeDoc

296 |
297 |
298 | 299 | 300 | 301 | -------------------------------------------------------------------------------- /docs/classes/_channel_.channel.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | Channel | urbit-airlock 7 | 8 | 9 | 10 | 11 | 12 |
13 |
14 |
15 |
16 | 27 |
28 |
29 | Options 30 |
31 |
32 | All 33 |
    34 |
  • Public
  • 35 |
  • Public/Protected
  • 36 |
  • All
  • 37 |
38 |
39 | 40 | 41 | 42 | 43 | 44 | 45 |
46 |
47 | Menu 48 |
49 |
50 |
51 |
52 |
53 |
54 | 65 |

Class Channel

66 |
67 |
68 |
69 |
70 |
71 |
72 |
73 |
74 |
75 |

A Channel is an HTTP connection to a running Urbit. Using it, you can poke and subscribe to agents

76 |
77 |
78 |
79 |
80 |

Hierarchy

81 |
    82 |
  • 83 | Channel 84 |
  • 85 |
86 |
87 |
88 |

Index

89 |
90 |
91 |
92 |

Constructors

93 | 96 |
97 |
98 |

Methods

99 | 104 |
105 |
106 |
107 |
108 |
109 |

Constructors

110 |
111 | 112 |

constructor

113 | 116 |
    117 |
  • 118 | 123 |
    124 |
    125 |

    Parameters

    126 |
      127 |
    • 128 |
      conn: UrbitConnection
      129 |
      130 |
      131 |

      Object describing connection to urbit

      132 |
      133 |
      134 |
    • 135 |
    136 |

    Returns Channel

    137 |
  • 138 |
139 |
140 |
141 |
142 |

Methods

143 |
144 | 145 |

poke

146 |
    147 |
  • poke<M>(app: string, cage: Cage<M>): Promise<void>
  • 148 |
149 |
    150 |
  • 151 | 156 |
    157 |
    158 |

    Poke a Gall agent with a cage.

    159 |
    160 |
    161 |

    Type parameters

    162 |
      163 |
    • 164 |

      M: Mark

      165 |
    • 166 |
    167 |

    Parameters

    168 |
      169 |
    • 170 |
      app: string
      171 |
      172 |

      name of Gall agent to send poke to

      173 |
      174 |
    • 175 |
    • 176 |
      cage: Cage<M>
      177 |
      178 |

      The cage to poke the agent with

      179 |
      180 |
    • 181 |
    182 |

    Returns Promise<void>

    183 |

    A promise that resolves when the poke is successfully 184 | executed and rejects when the poke errors

    185 |
  • 186 |
187 |
188 |
189 | 190 |

subscribe

191 | 194 |
    195 |
  • 196 | 201 |
    202 |
    203 |

    Subscribe to a Gall agent on a path, executing handlers on each event or on subscription quit or subscription error. 204 | See also: unsubscribe

    205 |
    206 |
    207 |

    Type parameters

    208 |
      209 |
    • 210 |

      M: Mark

      211 |
    • 212 |
    213 |

    Parameters

    214 |
      215 |
    • 216 |
      app: string
      217 |
      218 |

      name of Gall agent to subscribe to

      219 |
      220 |
    • 221 |
    • 222 |
      path: string
      223 |
      224 |

      path to subscribe on

      225 |
      226 |
    • 227 |
    • 228 |
      handlers: OutstandingSubscription<M>
      229 |
      230 |

      event handlers for the subscription

      231 |
      232 |
    • 233 |
    234 |

    Returns number

    235 |

    a subscription id, which can be used to cancel the subscription

    236 |
  • 237 |
238 |
239 |
240 | 241 |

unsubscribe

242 |
    243 |
  • unsubscribe(subscription: number): void
  • 244 |
245 |
    246 |
  • 247 | 252 |
    253 |
    254 |

    Cancel a subscription to a gall agent

    255 |
    256 |
    257 |

    Parameters

    258 |
      259 |
    • 260 |
      subscription: number
      261 |
      262 |

      the ID returned from subscribe

      263 |
      264 |
    • 265 |
    266 |

    Returns void

    267 |
  • 268 |
269 |
270 |
271 |
272 | 333 |
334 |
335 |
336 |
337 |

Legend

338 |
339 |
    340 |
  • Function
  • 341 |
  • Type alias
  • 342 |
  • Type alias with type parameter
  • 343 |
344 |
    345 |
  • Class
  • 346 |
  • Constructor
  • 347 |
  • Method
  • 348 |
349 |
    350 |
  • Interface
  • 351 |
  • Interface with type parameter
  • 352 |
353 |
354 |
355 |
356 |
357 |

Generated using TypeDoc

358 |
359 |
360 | 361 | 362 | 363 | --------------------------------------------------------------------------------