Skip to content

Commit 05a4efe

Browse files
authored
Merge pull request #70 from microcmsio/docs/get-all-contents
READMEにgetAllContentsを追加
2 parents 5612ec3 + 451cb64 commit 05a4efe

File tree

1 file changed

+21
-0
lines changed

1 file changed

+21
-0
lines changed

README.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -147,6 +147,27 @@ client
147147
.then((res) => console.log(res))
148148
.catch((err) => console.error(err));
149149
```
150+
151+
#### Get all contents
152+
153+
This function can be used to retrieve all content data.
154+
155+
```javascript
156+
client
157+
.getAllContents({
158+
endpoint: 'endpoint',
159+
})
160+
.then((res) => console.log(res))
161+
.catch((err) => console.error(err));
162+
163+
// with queries
164+
client
165+
.getAllContents({
166+
endpoint: 'endpoint',
167+
queries: { filters: 'createdAt[greater_than]2021', orders: '-createdAt' },
168+
})
169+
.then((res) => console.log(res))
170+
.catch((err) => console.error(err));
150171
```
151172

152173
#### CREATE API

0 commit comments

Comments
 (0)