<commit_before>[![Build Status](https://travis-ci.org/cloudfoundry-incubator/routing-api-cli.svg)](https://travis-ci.org/cloudfoundry-incubator/routing-api-cli)

# Routing API CLI

The Routing API CLI lets you list, register, and unregister routes with the Cloud Foundry [Routing API](https://github.com/cloudfoundry-incubator/routing-api).

**Note**: This repository should be imported as `code.cloudfoundry.org/routing-api-cli`.

**Note**: This repository was built as an internal tool and is not actively maintained. Your mileage may vary.

## Dependencies

The Routing API uses OAuth tokens to authenticate clients. To obtain a token from UAA an OAuth client must first be created for the API client in UAA. For instructions on registering OAuth clients, see [Routing API Server Configuration](https://github.com/cloudfoundry-incubator/routing-api#oauth-clients).

## Installation

### Download Binaries

Download the binary at [Releases](https://github.com/cloudfoundry-incubator/routing-api-cli/releases). Move the binary to a directory in your $PATH. Run `rtr -v` to confirm that the Routing API CLI is working properly.

### Compile

- Go should be installed and in the PATH
- Checkout code and set GOPATH based on [routing-release](https://github.com/cloudfoundry-incubator/routing-release#-get-the-code)
- Build the binary, and place it in your gopath:

  ```bash
  cd $GOPATH/src/code.cloudfoundry.org/routing-api-cli
  go build -o $GOPATH/bin/rtr
  ```

## Usage

Each command has required arguments and route structure.

Required arguments:

**--api**: the routing API endpoint, e.g. `http://api.10.244.0.34.xip.io`<br />
**--client-id**: the id of the client registered with your OAuth provider with the [proper authorities](https://github.com/cloudfoundry-incubator/routing-api#oauth-clients), e.g. `routing_api_client`<br />
**--client-secret**: your OAuth client secret, e.g. `route_secret`<br />
**--oauth-url**: the OAuth provider endpoint with optional port, e.g. `http://uaa.10.244.0.34.xip.io`<commit_msg>Fix broken links in the README.<commit_after>[![Build Status](https://travis-ci.org/cloudfoundry/routing-api-cli.svg)](https://travis-ci.org/cloudfoundry/routing-api-cli)

# Routing API CLI

The Routing API CLI lets you list, register, and unregister routes with the
Cloud Foundry [Routing API](https://github.com/cloudfoundry/routing-api).

**Note**: This repository should be imported as
`code.cloudfoundry.org/routing-api-cli`.

**Note**: This repository was built as an internal tool and is not actively maintained. Your mileage may vary.

## Dependencies

The Routing API uses OAuth tokens to authenticate clients. To obtain a token
from UAA an OAuth client must first be created for the API client in UAA. For
instructions on registering OAuth clients, see [Routing API Server
Configuration](https://github.com/cloudfoundry-incubator/routing-api#oauth-clients).

## Installation

### Download Binaries

Download the binary at
[Releases](https://github.com/cloudfoundry/routing-api-cli/releases). Move the
binary to a directory in your $PATH. Run `rtr -v` to confirm that the Routing
API CLI is working properly.

### Compile

- Go should be installed and in the PATH
- Checkout code and set GOPATH based on
  [routing-release](https://github.com/cloudfoundry/routing-release#get-the-code)
- Build the binary, and place it in your gopath:

  ```bash
  cd $GOPATH/src/code.cloudfoundry.org/routing-api-cli
  go build -o $GOPATH/bin/rtr
  ```

## Usage

Each command has required arguments and route structure.

Required arguments:

**--api**: the routing API endpoint, e.g. `http://api.10.244.0.34.xip.io`<br />
**--client-id**: the id of the client registered with your OAuth provider with the [proper authorities](https://github.com/cloudfoundry/routing-api#oauth-clients), e.g. `routing_api_client`<br />
**--client-secret**: your OAuth client secret, e.g. `route_secret`<br />
**--oauth-url**: the OAuth provider endpoint with optional port, e.g. `http://uaa.10.244.0.34.xip.io`
{'fraction_non_alphanumeric': 0.12509344629952654, 'fraction_numerical': 0.00797408422626464, 'mean_word_length': 4.424324324324324, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 9, 'https://': 14, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 4, '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': '579859', 'n_tokens_mistral': 1275, 'n_tokens_neox': 1254, 'n_words': 410}