Skip to content

Commit

Permalink
Merge pull request #18 from oasysgames/refactor/readme_chapter
Browse files Browse the repository at this point in the history
modify README chapter
  • Loading branch information
Tsuyoshi-Ishikawa authored Mar 6, 2023
2 parents 45b66d6 + 0b2f775 commit 968a204
Showing 1 changed file with 15 additions and 15 deletions.
30 changes: 15 additions & 15 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ Verse-Proxy can control following items.
- jsonrpc method
- transaction's from, to, value
- address which can deploy smart contract

- transaction access rate

## Verse Proxy Build Steps

Expand Down Expand Up @@ -73,6 +73,12 @@ docker run --name verse-proxy -d -p $PORT:$PORT -v $PWD/src/config:/usr/src/app/

## Control items

### Set allowed header
You can set whether you inherit proxy request's host header on verse request at `src/config/configuration.ts`.
```typescript
inheritHostHeader: true,
```

### Set allowed verse request methods
You can set allowed verse request methods by regex at `src/config/configuration.ts`.
```typescript
Expand Down Expand Up @@ -131,7 +137,7 @@ export const getTxAllowList = (): Array<TransactionAllow> => {
```

```typescript
// ! is denial.
// ! is exception_pattern.

// 0xaf395754eB6F542742784cE7702940C60465A46a are not allowed to be transacted.
// But any address other than 0xaf395754eB6F542742784cE7702940C60465A46a are allowed to be transacted.
Expand Down Expand Up @@ -172,7 +178,7 @@ export const getTxAllowList = (): Array<TransactionAllow> => {
```

```typescript
// You can not set setting with address and address_denial.
// You can not set setting with normal_address and exception_pattern.
export const getTxAllowList = (): Array<TransactionAllow> => {
return [
{
Expand Down Expand Up @@ -236,8 +242,11 @@ export const getTxAllowList = (): Array<TransactionAllow> => {
| lt | txValue < condition is allowed |
| lte | txValue <= condition is allowed |

#### Deployer
You can control deployer of a verse.
#### Transaction access rate limit(Option)
If you set transaction access rate limit, follow [Transaction access rate limit](https://github.com/oasysgames/verse-proxy/blob/master/docs/RateLimit.md)

### Set contract deployer
You can control deployer of a verse at `src/config/transactionAllowList.ts`.

```typescript
// Only 0xaf395754eB6F542742784cE7702940C60465A46a can deploy
Expand All @@ -258,16 +267,7 @@ export const getDeployAllowList = (): Array<string> => {
};
```

### Transaction access rate limit(Option)
If you set transaction access rate limit, follow [Transaction access rate limit](/docs/RateLimit.md)

### Set allowed header
You can set whether you inherit proxy request's host header on verse request at `src/config/configuration.ts`.
```typescript
inheritHostHeader: true,
```

### Batch Request
## Batch Request
You can execute batch requests to the proxy.

If you want to make many transaction batch requests, change the parse limit in the body by environment variable.
Expand Down

0 comments on commit 968a204

Please sign in to comment.