Skip to content

Commit 7629e86

Browse files
committed
Remove /api from url pattern; add tests
1 parent 15b9068 commit 7629e86

15 files changed

+2120
-7394
lines changed

CHANGES.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ Version 1 of the SDK client only supported Node application because the final bu
55
The previous documentation often incorrectly showed the results of the methods having direct returns. In reality, all methods return a promise that resolves to the data shown.
66

77
- modzyClient initialization parameter change to single object. The `url` key is optional as it defaults to app.modzy.com
8-
- Deprecated(?) `.getAllModels`. Still works; returns the same response
8+
- Removed `.getAllModels`. use getActiveModels() or call getModels() with no params.
99
- Added `.getActiveModels`. Returns only the active models with more useful details
1010
- `.getModels` parameter change to single object.
1111
- `.getModel` renamed to `.getModelById`

README.md

+12-1
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ const modzyClient = new ModzyClient({
3838
// or for private Modzy instances
3939
const modzyClient = new ModzyClient({
4040
apiKey: "xxxxxxxxxxxxx.xxxxxxxxxxxxx",
41-
url: "https://modzy.yourdomain.com/api
41+
url: "https://modzy.yourdomain.com",
4242
});
4343
```
4444

@@ -215,6 +215,17 @@ Samples are intended to be run using Node, but most can also run in the browser.
215215

216216
---
217217

218+
## Running tests
219+
220+
The Jest tests expect that there is a .env file at the root of the repo that contains a
221+
valid app.modzy.com api key like this:
222+
223+
```
224+
API_KEY=xxxxxxxxxxxxxxxxxxxx.xxxxxxxxxxxxxxxxxxxx
225+
```
226+
227+
---
228+
218229
## Contributing
219230

220231
We are happy to receive contributions from all of our users. Check out our [contributing file](https://github.com/modzy/sdk-javascript/tree/main/contributing.adoc) to learn more.

0 commit comments

Comments
 (0)