aboutsummaryrefslogtreecommitdiffstats
path: root/packages/pipeline/src/models/order.ts
diff options
context:
space:
mode:
Diffstat (limited to 'packages/pipeline/src/models/order.ts')
-rw-r--r--packages/pipeline/src/models/order.ts30
1 files changed, 30 insertions, 0 deletions
diff --git a/packages/pipeline/src/models/order.ts b/packages/pipeline/src/models/order.ts
new file mode 100644
index 000000000..dadae2883
--- /dev/null
+++ b/packages/pipeline/src/models/order.ts
@@ -0,0 +1,30 @@
+const order = {
+ tableName: 'orders',
+ tableProperties: {
+ id: {
+ type: 'key',
+ },
+ timestamp: {
+ type: 'timestamp',
+ required: true,
+ },
+ block_number: {
+ type: 'bigint',
+ required: true,
+ },
+ },
+};
+const logToOrderSchemaMapping: any = {
+ exchangeContractAddress: 'exchange_contract_address',
+ maker: 'maker',
+ makerTokenAddress: 'maker_token',
+ makerTokenAmount: 'maker_amount',
+ makerFee: 'maker_fee',
+ taker: 'taker',
+ takerTokenAddress: 'taker_token',
+ takerTokenAmount: 'taker_amount',
+ takerFee: 'taker_fee',
+ expirationUnixTimestampSec: 'expiration_unix_timestamp_sec',
+ salt: 'salt',
+};
+export { order, logToOrderSchemaMapping };