Skip to content

Commit

Permalink
Add tutorial
Browse files Browse the repository at this point in the history
  • Loading branch information
arnoerpenbeck committed Sep 5, 2024
1 parent 74bb68b commit d6c2551
Showing 1 changed file with 8 additions and 7 deletions.
15 changes: 8 additions & 7 deletions TUTORIAL.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,9 @@ This tutorial will guide you through the first steps to get started with the ful
## Requirements

To follow this tutorial, you will need to:
* have [access](https://docs.fulfillmenttools.com/api-docs/getting-started/setup-your-access-to-fulfillmenttools) to a fulfillmenttools project
* have a basic understanding of [TypeScript](https://www.typescriptlang.org/)
* have access to a fulfillmenttools project
* have [Node.js](https://docs.npmjs.com/downloading-and-installing-node-js-and-npm) LTS or later installed
* have a JavaScript package manager such as npm or yarn installed
* have [Node.js](https://docs.npmjs.com/downloading-and-installing-node-js-and-npm) and npm installed

If you're new to Node.js development, start with one of the many tutorials on the web, e.g. [this one from MDN](https://developer.mozilla.org/en-US/docs/Learn/Server-side/Express_Nodejs/development_environment).

Expand Down Expand Up @@ -45,7 +44,6 @@ cd hello-fft
Next, run the following commands to initialize the project:

```bash
git init
npm init -y
```

Expand Down Expand Up @@ -95,7 +93,7 @@ This command adds the TypeScript SDK to your project and lists it as a necessary

### Add environment variables

You can store your credentials in an `.env` file, but make sure not to check it into your GitHub repository:
You can store your credentials in an `.env` file, but make sure not to check it into your code repository:

```INI
FFT_PROJECT_ID={projectId}
Expand Down Expand Up @@ -123,7 +121,6 @@ Your `hello-fft` directory should now look like this:

```
.env
.git
node_modules/
package-lock.json
package.json
Expand Down Expand Up @@ -164,6 +161,9 @@ const fftApiClient = new FftApiClient(
const fftFacilityService = new FftFacilityService(fftApiClient);
```

> [!NOTE]
> The `FftApiClient` will handle the autorization process, so you do not have to obtain/renew API tokens explicitly.
### Make an API call

Now you are ready to actually make a call to the fulfillmenttools REST API using your client.
Expand Down Expand Up @@ -201,6 +201,7 @@ You are now ready to use the fulfillmenttools TypeScript SDK in your Node.js pro

You can explore the other functions offered by the SDK, e.g. to create an order using `FftOrderService`, work with pick jobs using `FftPickJobService`, or try out the checkout options using `FftOrderPromisingService`, ...

If you find anything missing or spot anything unusual, please use the [GitHub issues](https://github.com/fulfillmenttools/fulfillmenttools-sdk-typescript/issues) to get in touch. Feel free to reach out to us at [opensource@fulfillmenttools.com](mailto:opensource@fulfillmenttools.com) if you have any questions about the TypeScript SDK or our other open source projects.
> [!TIP]
> If you find anything missing or spot anything unusual, please use the [GitHub issues](https://github.com/fulfillmenttools/fulfillmenttools-sdk-typescript/issues) to get in touch. Feel free to reach out to us at [opensource@fulfillmenttools.com](mailto:opensource@fulfillmenttools.com) if you have any questions about the TypeScript SDK or our other open source projects.
Happy coding!

0 comments on commit d6c2551

Please sign in to comment.