about summary refs log tree commit diff
path: root/src/temp/dm/getChat.ts
blob: d0a7b891c2fa82039476bc002eb9d0de0fbefe64 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
import {Headers, XRPCError} from '@atproto/xrpc'

import * as TempDmDefs from './defs'

export interface QueryParams {
  chatId: string
}

export type InputSchema = undefined

export interface OutputSchema {
  chat: TempDmDefs.ChatView
  [k: string]: unknown
}

export interface CallOptions {
  headers?: Headers
}

export interface Response {
  success: boolean
  headers: Headers
  data: OutputSchema
}

export function toKnownErr(e: any) {
  if (e instanceof XRPCError) {
  }
  return e
}