diff --git a/gatewayd.md b/gatewayd.md
index 6c1bc93eb7..525b4de316 100644
--- a/gatewayd.md
+++ b/gatewayd.md
@@ -41,13 +41,13 @@ Gatewayd's features include:
## Configuration ##
-Before you can run gatewayd, you need to set up the appropriate accounts that will be used to store and send funds in the Ripple network. You also need to define which currencies your gateway issues. Beyond that, there are some options you can set if they set your needs.
+Before you can run gatewayd, you need to set up the appropriate accounts that will be used to store and send funds in the Ripple network. You also need to define which currencies your gateway issues. Beyond that, there are some options you can set if they fit your needs.
-The defaults for all of gatewayd's settings are found in the file `config/config.js`. You can override any of those settings with your own values by editing them in the file `config/config.json`. Don't mix up these two files!
+The defaults for all of gatewayd's settings are found in the file `config/config.js`. You can override any of those settings with your own values by editing them in the file `config/config.json`, or by using the API methods for setting the configuration. (The API methods result in editing the `config/config.json` file anyway.) You don't need to edit the `config/config.js` file, since that only contains the defaults, and gets overridden in a software update.
### Hot Wallet, Cold Wallet, Trust ###
-When a gateway issues balances of non-XRP currencies on the Ripple Network, those balances become liabilities in the real world that must be covered when people redeem those balances as external withdrawals. Additionally, actual XRP balances are digital assets that can be stolen or lost. Gatewayd uses the concept of a "hot wallet" and a "cold wallet" to minimize the risk of losses. (In practice, there is no difference between the term "wallet" and "account" on Ripple.)
+When a gateway issues balances of non-XRP currencies on the Ripple Network, those balances become liabilities in the real world that must be covered when people redeem those balances as external withdrawals. Additionally, actual XRP balances are digital assets that can be stolen or lost. Gatewayd uses the concept of a "hot wallet" and a "cold wallet" to minimize the risk of losses for both categories. (In practice, there is no difference between the term "wallet" and "account" on Ripple.)
The cold wallet is like your vault. It issues all your funds, and holds the bulk of your XRP assets. The secret key that is used for this wallet is kept offline, accessible to a few trusted operators. Every now and then, the cold wallet is used to refill the stores in the hot wallet.
@@ -55,7 +55,7 @@ The hot wallet is like your cash register. It holds a small amount of funds at a
All issuances of non-XRP currency and assets come from the cold wallet; it effectively 'creates' the currency on the Ripple Network to mirror the deposits received via external transactions. Consequently, Ripple accounts (customers as well as the hot wallet) must trust the cold wallet account in order to hold currency issued by that gateway. (Trusting a gateway means that you believe its issuances are worth something.) Customers do not need to trust the hot wallet, and should not.
-Although you could send the issuances directly to customers from the account issuing them, that exposes you to risk: if the account issuing the currency is compromised, potentially unlimited Issuances could be made on your behalf. Using a hot/cold wallet distinction decreases the chances that your issuing account will be compromised, because you can keep it safely offline while day-to-day business is happening. The hot wallet, which is exposed to the most risk, can only lose as much money as it holds.
+Although you could send the issuances directly to customers from the account issuing them, that exposes you to risk: if the account issuing the currency is compromised, potentially unlimited issuances could be made on your behalf. Using a hot/cold wallet distinction decreases the chances that your issuing account will be compromised, because you can keep it safely offline while day-to-day business is happening. The hot wallet, which is exposed to the most risk, can only lose as much money as it holds.
### Setting Up Wallets for gatewayd
@@ -101,7 +101,7 @@ The last step before you can start your gateway is to set the last payment hash.
The update process for gatewayd may change in the future, but for now, updating to a new version follows this process:
-(Not totally sure about the commandline syntax for all of these
+(Need to confirm that this is the correct commandline syntax for all of these)
1. Use git to pull the `master` branch [from Github](https://github.com/ripple/gatewayd.git). (This assumes you created it by using `git clone` on the repository first.)
`git pull`
@@ -124,14 +124,16 @@ After installation, start the gateway processes by running the command:
## Gatewayd Architecture
-A gateway acts as a link between the Ripple Network and activities outside of the network, such as traditional banking activities. Thus, gatewayd sits between the `rippled` server (which participates in the network) and some source of information about external activities. (This could be custom banking software that is aware of deposits and withdrawals, or it could even be manually monitored.)
+A gateway acts as a link between Ripple's shared global Ledger and value outside of the network, such as traditional banking balances, other virtual currencies, or more. Thus, gatewayd sits between the `rippled` server (which participates in the network that defines the Ripple global ledger) and some source of information about external activities. Gatewayd's main job is to monitor each side for transactions and translate them into the appropriate actions on the other side.
+
+In short, you can
Gatewayd is implemented as a [Node.js](http://nodejs.org/) web application that keeps track of transactions that are entering and leaving the Ripple Network, and exposes a RESTful API for configuring and controlling its behavior. It persists transactions to a [Postgres database](http://www.postgresql.org/). This application has 6 main processes that comprise its operation:
| Process | Purpose |
|---------|---------|
| server | Provides the RESTful API for controlling gatewayd and querying about its status; also serves a ripple.txt file to identify the gateway. |
-| ripple-rest | Provides a [Ripple-REST](?p=ripple-rest-api) service that communicates with a `rippled` server. |
+| ripple-rest | Provides a [Ripple-REST](?p=ripple-rest) service that communicates with a `rippled` server. |
| incoming | Monitors the Ripple Network for incoming Ripple payments |
| withdrawals | Converts records of incoming Ripple payments into pending withdrawal records |
| outgoing | Sends pending Ripple payments out to the network to issue balances |
@@ -491,7 +493,7 @@ $ bin/gateway deactivate_user 508
```
//id: integer account ID
//callback: function f(err, user) to run on callback
-gateway.api.deactivateUser(id, callback)
+gateway.api.deactivateUser(id, callback);
```
@@ -524,9 +526,21 @@ Response Body:
```
### Log In User ###
-This method appears not to exist in the usual places in the [source code](https://github.com/ripple/gatewayd/blob/master/lib/http/routers/api_router.js) [[2]](https://github.com/ripple/gatewayd/blob/master/bin/gateway)?
+[[Source]
](https://github.com/ripple/gatewayd/blob/master/lib/http/controllers/public/login_user.js "Source")
-__`POST /v1/users/login`__
+