<commit_before># Introduction

[Flow XO](https://flowxo.com) is a platform that lets users build automated sales & marketing workflows on top of their existing cloud apps.

Each supported service is built as a _module_ which is called by the Flow XO _core_. A service is split into separate _methods_, and each method is either a _trigger_ (looks for new records, or receives new records via a webhook) or an _action_ (creates, updates or deletes records).

We've opened up our SDK so that anyone can build support for their service into Flow XO. The SDK gives you scaffolding for your service, a command-line tool to run your methods locally, tools to write tests and some examples of working services. Not forgetting these docs which should hopefully guide you through the process.

If you get stuck, just send us an email at [<EMAIL>](mailto:<EMAIL>) and we'll try our best to guide you.

# Prerequisites

Flow XO runs on [Node.js](https://nodejs.org/). If you don't have Node.js, you can [download it here](https://nodejs.org/download/). Make sure you're using Node.js v0.12.x as that's the version we run.

You'll also need to be familiar with [Git](http://git-scm.com/) as you'll be using it to submit your service for review. We use [GitHub](http://github.com) to host the services code, and you'll need to be familiar with forking and creating pull requests, as this is the workflow we will be using to validate your service.

As most modules will be fairly thin wrappers around HTTP API's, you should understand how to make HTTP requests in Node. We encourage you to use the popular [Request](https://github.com/request/request) module, but you can choose to make requests with Node's plain [https](https://nodejs.org/api/https.html) API if you prefer.

Finally, build and test related tasks are handled by the JavaScript task runner [Grunt](http://gruntjs.com/) so a working knowledge of this is useful.

That's all. The other tools that the SDK uses will be installed locally with `npm install`.

# Example Services

Use our example services as a reference when building your service:

- [Trello Example](https://github.com/flowxo/flowxo-services-trello-example) - uses OAuth1 for authentication.

_(We're hoping to bring you more examples soon!)_

# Scaffolding Your Service

To make it easy to build your service, we've written a [Yeoman](http://yeoman.io/) generator, which complements this SDK. You should install and use this to scaffold your service:

``` bash
npm install -g yo flowxo/generator-flowxo
```

You should now be able to run `yo flowxo` to generate a service.

If you select a _Credentials_ service, you'll be asked to define the fields that the user must complete. Normally this would be a username, password, API key, token, account name, etc. Just define all the fields you'll need to collect in order to access and authorize against your service's API. See the _Authorization > Credentials_ section for more information.<commit_msg>Updated generator installation instructions<commit_after># Introduction

[Flow XO](https://flowxo.com) is a platform that lets users build automated sales & marketing workflows on top of their existing cloud apps.

Each supported service is built as a _module_ which is called by the Flow XO _core_. A service is split into separate _methods_, and each method is either a _trigger_ (looks for new records, or receives new records via a webhook) or an _action_ (creates, updates or deletes records).

We've opened up our SDK so that anyone can build support for their service into Flow XO. The SDK gives you scaffolding for your service, a command-line tool to run your methods locally, tools to write tests and some examples of working services. Not forgetting these docs which should hopefully guide you through the process.

If you get stuck, just send us an email at [<EMAIL>](mailto:<EMAIL>) and we'll try our best to guide you.

# Prerequisites

Flow XO runs on [Node.js](https://nodejs.org/). If you don't have Node.js, you can [download it here](https://nodejs.org/download/). Make sure you're using Node.js v0.12.x as that's the version we run.

You'll also need to be familiar with [Git](http://git-scm.com/) as you'll be using it to submit your service for review. We use [GitHub](http://github.com) to host the services code, and you'll need to be familiar with forking and creating pull requests, as this is the workflow we will be using to validate your service.

As most modules will be fairly thin wrappers around HTTP API's, you should understand how to make HTTP requests in Node. We encourage you to use the popular [Request](https://github.com/request/request) module, but you can choose to make requests with Node's plain [https](https://nodejs.org/api/https.html) API if you prefer.

Finally, build and test related tasks are handled by the JavaScript task runner [Grunt](http://gruntjs.com/) so a working knowledge of this is useful.

That's all. The other tools that the SDK uses will be installed locally with `npm install`.

# Example Services

Use our example services as a reference when building your service:

- [Trello Example](https://github.com/flowxo/flowxo-services-trello-example) - uses OAuth1 for authentication.

_(We're hoping to bring you more examples soon!)_

# Scaffolding Your Service

To make it easy to build your service, we've written a [Yeoman](http://yeoman.io/) generator, which complements this SDK. You should install and use this to scaffold your service:

``` bash
npm install -g yo generator-flowxo
```

You should now be able to run `yo flowxo` to generate a service.

If you select a _Credentials_ service, you'll be asked to define the fields that the user must complete. Normally this would be a username, password, API key, token, account name, etc. Just define all the fields you'll need to collect in order to access and authorize against your service's API. See the _Authorization > Credentials_ section for more information.
{'fraction_non_alphanumeric': 0.0686817800167926, 'fraction_numerical': 0.001343408900083963, 'mean_word_length': 4.390045248868779, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 9, 'https://': 12, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 4, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7402894', 'n_tokens_mistral': 1605, 'n_tokens_neox': 1522, 'n_words': 886}