mirror of
https://github.com/simplex-chat/simplex-chat.git
synced 2026-07-12 22:39:02 +00:00
simplex-chat: sync nodejs and python libs with 7.0.0-beta.3 types (#7219)
This commit is contained in:
@@ -688,7 +688,7 @@ export class ChatApi {
|
||||
* Network usage: interactive.
|
||||
*/
|
||||
async apiConnectPlan(userId: number, connectionLink: string): Promise<[T.ConnectionPlan, T.CreatedConnLink]> {
|
||||
const r = await this.sendChatCmd(CC.APIConnectPlan.cmdString({userId, connectionLink, resolveKnown: false}))
|
||||
const r = await this.sendChatCmd(CC.APIConnectPlan.cmdString({userId, connectTarget: connectionLink, resolveMode: T.PlanResolveMode.Unknown}))
|
||||
if (r.type === "connectionPlan") return [r.connectionPlan, r.connLink]
|
||||
throw new ChatCommandError("error getting connect plan", r)
|
||||
}
|
||||
@@ -707,7 +707,7 @@ export class ChatApi {
|
||||
* Network usage: interactive.
|
||||
*/
|
||||
async apiConnectActiveUser(connLink: string): Promise<ConnReqType> {
|
||||
const r = await this.sendChatCmd(CC.Connect.cmdString({incognito: false, connLink_: connLink}))
|
||||
const r = await this.sendChatCmd(CC.Connect.cmdString({incognito: false, connTarget_: connLink}))
|
||||
return this.handleConnectResult(r)
|
||||
}
|
||||
|
||||
@@ -866,7 +866,7 @@ export class ChatApi {
|
||||
* Network usage: no.
|
||||
*/
|
||||
async apiCreateActiveUser(profile?: T.Profile): Promise<T.User> {
|
||||
const r = await this.sendChatCmd(CC.CreateActiveUser.cmdString({newUser: {profile, pastTimestamp: false, userChatRelay: false}}))
|
||||
const r = await this.sendChatCmd(CC.CreateActiveUser.cmdString({newUser: {profile, pastTimestamp: false, userChatRelay: false, clientService: false}}))
|
||||
if (r.type === "activeUser") return r.user
|
||||
throw new ChatCommandError("unexpected response", r)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user