Skip to content

Commit

Permalink
idl
Browse files Browse the repository at this point in the history
  • Loading branch information
skrrb committed Feb 2, 2024
1 parent 3a06313 commit 23fc295
Show file tree
Hide file tree
Showing 2 changed files with 338 additions and 0 deletions.
114 changes: 114 additions & 0 deletions idl/openbook_v2.json
Original file line number Diff line number Diff line change
Expand Up @@ -620,6 +620,120 @@
"option": "u128"
}
},
{
"name": "placeOrders",
"docs": [
"Place multiple orders"
],
"accounts": [
{
"name": "signer",
"isMut": false,
"isSigner": true
},
{
"name": "openOrdersAccount",
"isMut": true,
"isSigner": false
},
{
"name": "openOrdersAdmin",
"isMut": false,
"isSigner": true,
"isOptional": true
},
{
"name": "userQuoteAccount",
"isMut": true,
"isSigner": false
},
{
"name": "userBaseAccount",
"isMut": true,
"isSigner": false
},
{
"name": "market",
"isMut": true,
"isSigner": false
},
{
"name": "bids",
"isMut": true,
"isSigner": false
},
{
"name": "asks",
"isMut": true,
"isSigner": false
},
{
"name": "eventHeap",
"isMut": true,
"isSigner": false
},
{
"name": "marketQuoteVault",
"isMut": true,
"isSigner": false
},
{
"name": "marketBaseVault",
"isMut": true,
"isSigner": false
},
{
"name": "oracleA",
"isMut": false,
"isSigner": false,
"isOptional": true
},
{
"name": "oracleB",
"isMut": false,
"isSigner": false,
"isOptional": true
},
{
"name": "tokenProgram",
"isMut": false,
"isSigner": false
}
],
"args": [
{
"name": "ordersType",
"type": {
"defined": "PlaceOrderType"
}
},
{
"name": "bids",
"type": {
"vec": {
"defined": "PlaceMultipleOrdersArgs"
}
}
},
{
"name": "asks",
"type": {
"vec": {
"defined": "PlaceMultipleOrdersArgs"
}
}
},
{
"name": "limit",
"type": "u8"
}
],
"returns": {
"vec": {
"option": "u128"
}
}
},
{
"name": "cancelAllAndPlaceOrders",
"docs": [
Expand Down
224 changes: 224 additions & 0 deletions ts/client/src/openbook_v2.ts
Original file line number Diff line number Diff line change
Expand Up @@ -616,6 +616,118 @@ export interface OpenbookV2 {
option: 'u128';
};
},
{
name: 'placeOrders';
docs: ['Place multiple orders'];
accounts: [
{
name: 'signer';
isMut: false;
isSigner: true;
},
{
name: 'openOrdersAccount';
isMut: true;
isSigner: false;
},
{
name: 'openOrdersAdmin';
isMut: false;
isSigner: true;
isOptional: true;
},
{
name: 'userQuoteAccount';
isMut: true;
isSigner: false;
},
{
name: 'userBaseAccount';
isMut: true;
isSigner: false;
},
{
name: 'market';
isMut: true;
isSigner: false;
},
{
name: 'bids';
isMut: true;
isSigner: false;
},
{
name: 'asks';
isMut: true;
isSigner: false;
},
{
name: 'eventHeap';
isMut: true;
isSigner: false;
},
{
name: 'marketQuoteVault';
isMut: true;
isSigner: false;
},
{
name: 'marketBaseVault';
isMut: true;
isSigner: false;
},
{
name: 'oracleA';
isMut: false;
isSigner: false;
isOptional: true;
},
{
name: 'oracleB';
isMut: false;
isSigner: false;
isOptional: true;
},
{
name: 'tokenProgram';
isMut: false;
isSigner: false;
},
];
args: [
{
name: 'ordersType';
type: {
defined: 'PlaceOrderType';
};
},
{
name: 'bids';
type: {
vec: {
defined: 'PlaceMultipleOrdersArgs';
};
};
},
{
name: 'asks';
type: {
vec: {
defined: 'PlaceMultipleOrdersArgs';
};
};
},
{
name: 'limit';
type: 'u8';
},
];
returns: {
vec: {
option: 'u128';
};
};
},
{
name: 'cancelAllAndPlaceOrders';
docs: ['Cancel orders and place multiple orders.'];
Expand Down Expand Up @@ -4189,6 +4301,118 @@ export const IDL: OpenbookV2 = {
option: 'u128',
},
},
{
name: 'placeOrders',
docs: ['Place multiple orders'],
accounts: [
{
name: 'signer',
isMut: false,
isSigner: true,
},
{
name: 'openOrdersAccount',
isMut: true,
isSigner: false,
},
{
name: 'openOrdersAdmin',
isMut: false,
isSigner: true,
isOptional: true,
},
{
name: 'userQuoteAccount',
isMut: true,
isSigner: false,
},
{
name: 'userBaseAccount',
isMut: true,
isSigner: false,
},
{
name: 'market',
isMut: true,
isSigner: false,
},
{
name: 'bids',
isMut: true,
isSigner: false,
},
{
name: 'asks',
isMut: true,
isSigner: false,
},
{
name: 'eventHeap',
isMut: true,
isSigner: false,
},
{
name: 'marketQuoteVault',
isMut: true,
isSigner: false,
},
{
name: 'marketBaseVault',
isMut: true,
isSigner: false,
},
{
name: 'oracleA',
isMut: false,
isSigner: false,
isOptional: true,
},
{
name: 'oracleB',
isMut: false,
isSigner: false,
isOptional: true,
},
{
name: 'tokenProgram',
isMut: false,
isSigner: false,
},
],
args: [
{
name: 'ordersType',
type: {
defined: 'PlaceOrderType',
},
},
{
name: 'bids',
type: {
vec: {
defined: 'PlaceMultipleOrdersArgs',
},
},
},
{
name: 'asks',
type: {
vec: {
defined: 'PlaceMultipleOrdersArgs',
},
},
},
{
name: 'limit',
type: 'u8',
},
],
returns: {
vec: {
option: 'u128',
},
},
},
{
name: 'cancelAllAndPlaceOrders',
docs: ['Cancel orders and place multiple orders.'],
Expand Down

0 comments on commit 23fc295

Please sign in to comment.