core/api-spec: rework tx template
core/api-spec: rework tx template

### Problem

I'm finding it confusing to describe transaction template - what it is and
what it's used for in different situations. For example, do you pass the
entire template to a counterparty for an atomic swap? At what point does it
become a transaction? When it's balanced? When it's signed? When it's
submitted?

A transaction template (as it currently stands) is really two things:

1. a raw transaction (that may or may not be balanced or signed)
2. instructions for signing inputs in the transaction

And it's used for three things:

1. instructing your HSM how to sign inputs you control in the transaction
2. submitting to the core to assemble signatures into the transaction.
3. sharing partial transaction with a counterparty in a multi-party
transaction (such as an atomic swap)

It seems that the instructions should remain private to the relevant party.
And the raw transaction can be passed around to couterparties to append
additional actions (inputs and outputs).

Additionally, as we are moving to deferred predicate (and we will pre-sign
atomic swaps), what will assemble the signatures into the
`raw_transaction`? Will we need a "Assemble Transaction" endpoint that adds
the signatures? Or will the HSM be able to do it? Seems like it's ideal for
the HSM to do it, since it's the only service that needs the instructions.

### Proposed Solution

1. Change endpoints to: `Build Transaction` and `Sign Transaction`
2. `transaction_template` contains two objects: `raw_transaction` and
`inputs_to_sign`
3. `Build Transaction` accepts an optional `raw_transaction` and returns a
`transaction_template`.
4. `Sign Transaction` adds signatures directly into the `raw_transaction`
in addition to `inputs_to_sign`. It still returns a `transaction_template`,
since signatures might need to be gathered from other HSMs.
5. To perform a multi-party transaction, the initiator builds/signs a
transaction and sends only the `raw_transaction` to the counterparty.
Counterparty passes the `raw_transaction` to the `Build Transaction`
endpoint to append additional actions.
6. `Submit Transaction` accepts only the `raw_transaction`

### Updates Required

1. update Build and Sign endpoint API paths
2. rename `transaction` to `raw_transaction` in build endpoint request
body
3. rename `transaction` to `raw_transaction` in transaction template
4. rename `inputs` to `inputs_to_sign` in transaction template
5. update mockHSM to accept new template naming
6. update mockHSM to insert signatures into `raw_transaction`

### Short Term Updates Required (for Fishco)
#### Java SDK
1. rename`TransactionTemplate.Builder()` to `Transaction.Builder()`
2. rename`TransactionTemplate.submit()` to `Transaction.submit()`
3. Transaction.submit() only sends `raw_transaction` to API

Closes chain/chainprv#1322

chain/chain,chain/chain,chain/chain,chain/chain,chain/chain,chain/chain