sayren Docs
스토어프론트 호스팅

스토어프론트 작업 트리 내용 검색

POST
/v1/storefront/site/files/search

Authorization

accessToken
headerAuthorizationBearer <token>

Sayren 계정 토큰(로그인 토큰 또는 개인 액세스 토큰, RFC 9068 JWT)

Header Parameters

X-Store-Id*string

대상 상점 id. 토큰의 상점 범위 밖이면 403 STORE_NOT_GRANTED, 없으면 400 STORE_ID_REQUIRED다

Request Body

application/json
  1. body
query*string
Length1 <= length <= 200
regex?boolean

query를 정규식으로 본다 (기본 false = 글자 그대로). 정규식은 100자까지이고 중첩 수량자((a+)+)·반복되는 선택((a|b)+)·역참조·뒤 보기, 가변 수량자(*·+·?·{n,m}, 넓은 범위는 2로 센다) 차수 4 초과는 400 INVALID_REQUEST다. 차수가 클수록 긴 줄은 건너뛰고 비용이 크면 truncated로 끊는다

caseSensitive?boolean

대소문자를 가리는가 (기본 false)

pathPrefix?string
Lengthlength <= 256
maxResults?integer

기본 50

Range1 <= value <= 200

Response Body

성공

application/json
  1. response
meta*
data*
error*|null
curl -X POST 'https://api.sayren.io/v1/storefront/site/files/search' \  -H 'X-Store-Id: string' \  -H 'Content-Type: application/json' \  -d '{  "query": "string"}'
{  "meta": {    "status": 200,    "code": "OK",    "message": "OK",    "isSuccess": true  },  "data": {    "matches": [      {        "path": "string",        "line": 1,        "column": 1,        "text": "string"      }    ],    "truncated": true  },  "error": null}