Skip to content

Commit

Permalink
docs(contributing): add instructions for local API setup
Browse files Browse the repository at this point in the history
Added steps for running cartridge API locally and environment
variable configuration to CONTRIBUTING.md for easier local
development setup.
  • Loading branch information
steebchen committed Jan 13, 2025
1 parent cb2ce8c commit d3fd074
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,3 +26,18 @@ graphql-client introspect-schema --output slot/schema.json https://api.cartridge
# Using this command actually change the macro to something auto-generated. And we prefer macro expansion.
# graphql-client generate --schema-path slot/schema.json slot/src/graphql/deployments/update.graphql
```

## Local Development

### Pointing to a local API

Run the cartridge api locally.

Then set these variables in your slot directory:

```shell
export CARTRIDGE_API_URL=http://localhost:8000
export CARTRIDGE_KEYCHAIN_URL=http://localhost:3001
```

Then run `cargo run -- <cmd>`.

0 comments on commit d3fd074

Please sign in to comment.