MCPcopy Create free account
hub / github.com/decaporg/decap-cms / getFileId

Method getFileId

packages/decap-cms-backend-gitlab/src/API.ts:747–756  ·  view source on GitHub ↗
(path: string, branch: string)

Source from the content-addressed store, hash-verified

745 }
746
747 async getFileId(path: string, branch: string) {
748 const request = await this.request({
749 method: 'HEAD',
750 url: `${this.repoURL}/repository/files/${encodeURIComponent(path)}`,
751 params: { ref: branch },
752 });
753
754 const blobId = request.headers.get('X-Gitlab-Blob-Id') as string;
755 return blobId;
756 }
757
758 async isFileExists(path: string, branch: string) {
759 const fileExists = await this.requestText({

Callers 4

APIClass · 0.95
allEntriesByFolderMethod · 0.80
allEntriesByFolderMethod · 0.80

Calls 2

requestMethod · 0.95
getMethod · 0.80

Tested by

no test coverage detected