Skip to content

Commit

Permalink
API-1821 Add details to README
Browse files Browse the repository at this point in the history
  • Loading branch information
dylanmartins committed Dec 5, 2023
1 parent bc5aba7 commit 476812b
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 5 deletions.
6 changes: 5 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -40,4 +40,8 @@ typehint:
# make executeSdkSample sample-file-name=metaproperties.py
.PHONY: executeSdkSample
executeSdkSample:
docker-compose exec bynder-python-sdk python /app/samples/$(sample-file-name)
docker-compose exec bynder-python-sdk python /app/samples/$(sample-file-name)

.PHONY: stop-docker
stop-docker:
docker-compose down
15 changes: 11 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -222,23 +222,30 @@ Ensure the following are installed on your machine:
Create a `secret.json` file by following the example provided in the project. Fill in the necessary settings based on your requirements. If you have a permanent token, only the domain and permanent_token fields need to be specified:
```
{
"domain": "https://example.bynder.com/api/",
"domain": "example.bynder.com", # Without the http:// or https://
"permanent_token": "7d09..........."
}
```

With `docker` and `docker-compose` installed, and your `secret.json` file ready, run the following command to initiate the container:
```
```bash
docker-compose up -d
```
This command initializes a container with the bynder-python-sdk installed and ready for use.

### Executing SDK Samples

Utilize the `Makefile` command to run SDK sample scripts. The syntax is as follows:
```
You can utilize the `Makefile` commands on your console to run SDK sample scripts. The syntax is as follows:
```bash
make executeSdkSample sample-file-name=file.py
```
All sample files are located in the `./samples` directory.

> :warning: Caution: The sample scripts are provided as examples. It is crucial to review and modify the commands before execution. The container updates automatically with changes, ensuring a seamless development experience. Always exercise caution when executing scripts.
## Stopping the Docker Container

When you're done with your development or testing, you can stop the Docker container using the following command:

```bash
make stop-docker

0 comments on commit 476812b

Please sign in to comment.