PlainApp
API 참조

앱 로그

기능 지원은 app.capabilities, 인가는 app.access와 호스트 권한으로 확인하세요. 예제는 합성 값을 사용합니다. 호출 전에 경로, ID, 입력, 필터를 바꾸세요.

타입 정의

graphql
type Mutation {
  clearAppLogs: Boolean!
  exportAppLogs: String
}

type Query {
  appLogFilesSize: Long!
  appLogPath: String!
  appLogs(query: String!, offset: Int!, limit: Int!): [String!]!
}

scalar Long

작업

mutation

clearAppLogs

앱 로그 파일을 지웁니다. 원격 호출은 개발자 모드가 필요합니다.

graphql
mutation clearAppLogs {
  clearAppLogs
}
mutation

exportAppLogs

앱 로그를 압축 파일로 내보내고 가능한 경우 경로를 반환합니다. 원격 호출은 개발자 모드가 필요합니다.

graphql
mutation exportAppLogs {
  exportAppLogs
}
query

appLogFilesSize

앱 로그 파일의 총 크기를 바이트 단위로 읽습니다. 원격 호출은 개발자 모드가 필요합니다.

graphql
query appLogFilesSize {
  appLogFilesSize
}
query

appLogPath

현재 앱 로그 경로를 읽습니다. 원격 호출은 개발자 모드가 필요합니다.

graphql
query appLogPath {
  appLogPath
}
query

appLogs

앱 로그 행을 최신순으로 페이지 단위로 읽거나 검색합니다. 원격 호출은 개발자 모드가 필요합니다.

graphql
# Log lines, newest first. A blank `query` pages the buffer directly;
# a non-blank one filters the whole buffer and then pages, so a
# search cannot be cut short by the page size.
query appLogs($query: String!, $offset: Int!, $limit: Int!) {
  appLogs(query: $query, offset: $offset, limit: $limit)
}