Skip to content
This repository has been archived by the owner on Apr 26, 2022. It is now read-only.

further class None examples #25

Open
martin0 opened this issue Jan 2, 2021 · 3 comments
Open

further class None examples #25

martin0 opened this issue Jan 2, 2021 · 3 comments

Comments

@martin0
Copy link

martin0 commented Jan 2, 2021

Please see the enclosed json
'''
{
"openapi": "3.0.0",
"info": {
"title": "Client Portal Web API",
"description": "Production version of the Client Portal Web API",
"version": "1.0.0"
},
"paths": {
"/trsrv/futures": {
"get": {
"summary": "Security Futures by Symbol",
"description": "Returns a list of non-expired future contracts for given symbol(s)",
"tags": [
"Contract"
],
"parameters": [
{
"in": "query",
"name": "symbols",
"description": "list of case-sensitive symbols separated by comma",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "returns an object with symbol and and array of its future contracts",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {
"symbol": {
"$ref": "#/components/schemas/futures"
}
}
}
}
}
},
"500": {
"description": "error while processing the request",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {
"error": {
"type": "string"
}
}
}
}
}
}
}
}
},
"/portfolio/{accountId}/summary": {
"get": {
"summary": "Account Summary",
"description": "Returns information about margin, cash balances and other information related to specified account. See also /portfolio/{accountId}/ledger. /portfolio/accounts or /portfolio/subaccounts must be called prior to this endpoint.",
"tags": [
"Account",
"Portfolio"
],
"parameters": [
{
"name": "accountId",
"in": "path",
"required": true,
"description": "account id",
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "returns an object containing account summary. The object contains multiple properties. A property is sufficed with -c if its provides commodity value, -s if it provides security value and -c if its UKL segment value",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {
"accountready": {
"$ref": "#/components/schemas/summary"
},
"accounttype": {
"$ref": "#/components/schemas/summary"
},
"accruedcash": {
"$ref": "#/components/schemas/summary"
},
"accruedcash-c": {
"$ref": "#/components/schemas/summary"
},
"accruedcash-f": {
"$ref": "#/components/schemas/summary"
},
"accruedcash-s": {
"$ref": "#/components/schemas/summary"
},
"accrueddividend": {
"$ref": "#/components/schemas/summary"
},
"accrueddividend-c": {
"$ref": "#/components/schemas/summary"
},
"accrueddividend-f": {
"$ref": "#/components/schemas/summary"
},
"accrueddividend-s": {
"$ref": "#/components/schemas/summary"
},
"availablefunds": {
"$ref": "#/components/schemas/summary"
},
"availablefunds-c": {
"$ref": "#/components/schemas/summary"
},
"availablefunds-f": {
"$ref": "#/components/schemas/summary"
},
"availablefunds-s": {
"$ref": "#/components/schemas/summary"
},
"billable": {
"$ref": "#/components/schemas/summary"
},
"billable-c": {
"$ref": "#/components/schemas/summary"
},
"billable-f": {
"$ref": "#/components/schemas/summary"
},
"billable-s": {
"$ref": "#/components/schemas/summary"
},
"buyingpower": {
"$ref": "#/components/schemas/summary"
},
"cushion": {
"$ref": "#/components/schemas/summary"
},
"daytradesremaining": {
"$ref": "#/components/schemas/summary"
},
"daytradesremainingt+1": {
"$ref": "#/components/schemas/summary"
},
"daytradesremainingt+2": {
"$ref": "#/components/schemas/summary"
},
"daytradesremainingt+3": {
"$ref": "#/components/schemas/summary"
},
"daytradesremainingt+4": {
"$ref": "#/components/schemas/summary"
},
"equitywithloanvalue": {
"$ref": "#/components/schemas/summary"
},
"equitywithloanvalue-c": {
"$ref": "#/components/schemas/summary"
},
"equitywithloanvalue-f": {
"$ref": "#/components/schemas/summary"
},
"equitywithloanvalue-s": {
"$ref": "#/components/schemas/summary"
},
"excessliquidity": {
"$ref": "#/components/schemas/summary"
},
"excessliquidity-c": {
"$ref": "#/components/schemas/summary"
},
"excessliquidity-f": {
"$ref": "#/components/schemas/summary"
},
"excessliquidity-s": {
"$ref": "#/components/schemas/summary"
},
"fullavailablefunds": {
"$ref": "#/components/schemas/summary"
},
"fullavailablefunds-c": {
"$ref": "#/components/schemas/summary"
},
"fullavailablefunds-f": {
"$ref": "#/components/schemas/summary"
},
"fullavailablefunds-s": {
"$ref": "#/components/schemas/summary"
},
"fullexcessliquidity": {
"$ref": "#/components/schemas/summary"
},
"fullexcessliquidity-c": {
"$ref": "#/components/schemas/summary"
},
"fullexcessliquidity-f": {
"$ref": "#/components/schemas/summary"
},
"fullexcessliquidity-s": {
"$ref": "#/components/schemas/summary"
},
"fullinitmarginreq": {
"$ref": "#/components/schemas/summary"
},
"fullinitmarginreq-c": {
"$ref": "#/components/schemas/summary"
},
"fullinitmarginreq-f": {
"$ref": "#/components/schemas/summary"
},
"fullinitmarginreq-s": {
"$ref": "#/components/schemas/summary"
},
"fullmaintmarginreq": {
"$ref": "#/components/schemas/summary"
},
"fullmaintmarginreq-c": {
"$ref": "#/components/schemas/summary"
},
"fullmaintmarginreq-f": {
"$ref": "#/components/schemas/summary"
},
"fullmaintmarginreq-s": {
"$ref": "#/components/schemas/summary"
},
"grosspositionvalue": {
"$ref": "#/components/schemas/summary"
},
"grosspositionvalue-c": {
"$ref": "#/components/schemas/summary"
},
"grosspositionvalue-f": {
"$ref": "#/components/schemas/summary"
},
"grosspositionvalue-s": {
"$ref": "#/components/schemas/summary"
},
"guarantee": {
"$ref": "#/components/schemas/summary"
},
"guarantee-c": {
"$ref": "#/components/schemas/summary"
},
"guarantee-f": {
"$ref": "#/components/schemas/summary"
},
"guarantee-s": {
"$ref": "#/components/schemas/summary"
},
"highestseverity": {
"$ref": "#/components/schemas/summary"
},
"highestseverity-c": {
"$ref": "#/components/schemas/summary"
},
"highestseverity-f": {
"$ref": "#/components/schemas/summary"
},
"highestseverity-s": {
"$ref": "#/components/schemas/summary"
},
"indianstockhaircut": {
"$ref": "#/components/schemas/summary"
},
"indianstockhaircut-c": {
"$ref": "#/components/schemas/summary"
},
"indianstockhaircut-f": {
"$ref": "#/components/schemas/summary"
},
"indianstockhaircut-s": {
"$ref": "#/components/schemas/summary"
},
"initmarginreq": {
"$ref": "#/components/schemas/summary"
},
"initmarginreq-c": {
"$ref": "#/components/schemas/summary"
},
"initmarginreq-f": {
"$ref": "#/components/schemas/summary"
},
"initmarginreq-s": {
"$ref": "#/components/schemas/summary"
},
"leverage": {
"$ref": "#/components/schemas/summary"
},
"leverage-c": {
"$ref": "#/components/schemas/summary"
},
"leverage-f": {
"$ref": "#/components/schemas/summary"
},
"leverage-s": {
"$ref": "#/components/schemas/summary"
},
"lookaheadavailablefunds": {
"$ref": "#/components/schemas/summary"
},
"lookaheadavailablefunds-c": {
"$ref": "#/components/schemas/summary"
},
"lookaheadavailablefunds-f": {
"$ref": "#/components/schemas/summary"
},
"lookaheadavailablefunds-s": {
"$ref": "#/components/schemas/summary"
},
"lookaheadexcessliquidity": {
"$ref": "#/components/schemas/summary"
},
"lookaheadexcessliquidity-c": {
"$ref": "#/components/schemas/summary"
},
"lookaheadexcessliquidity-f": {
"$ref": "#/components/schemas/summary"
},
"lookaheadexcessliquidity-s": {
"$ref": "#/components/schemas/summary"
},
"lookaheadinitmarginreq": {
"$ref": "#/components/schemas/summary"
},
"lookaheadinitmarginreq-c": {
"$ref": "#/components/schemas/summary"
},
"lookaheadinitmarginreq-f": {
"$ref": "#/components/schemas/summary"
},
"lookaheadinitmarginreq-s": {
"$ref": "#/components/schemas/summary"
},
"lookaheadmaintmarginreq": {
"$ref": "#/components/schemas/summary"
},
"lookaheadmaintmarginreq-c": {
"$ref": "#/components/schemas/summary"
},
"lookaheadmaintmarginreq-f": {
"$ref": "#/components/schemas/summary"
},
"lookaheadmaintmarginreq-s": {
"$ref": "#/components/schemas/summary"
},
"lookaheadnextchange": {
"$ref": "#/components/schemas/summary"
},
"maintmarginreq": {
"$ref": "#/components/schemas/summary"
},
"maintmarginreq-c": {
"$ref": "#/components/schemas/summary"
},
"maintmarginreq-f": {
"$ref": "#/components/schemas/summary"
},
"maintmarginreq-s": {
"$ref": "#/components/schemas/summary"
},
"netliquidation": {
"$ref": "#/components/schemas/summary"
},
"netliquidation-c": {
"$ref": "#/components/schemas/summary"
},
"netliquidation-f": {
"$ref": "#/components/schemas/summary"
},
"netliquidation-s": {
"$ref": "#/components/schemas/summary"
},
"netliquidationuncertainty": {
"$ref": "#/components/schemas/summary"
},
"nlvandmargininreview": {
"$ref": "#/components/schemas/summary"
},
"pasharesvalue": {
"$ref": "#/components/schemas/summary"
},
"pasharesvalue-c": {
"$ref": "#/components/schemas/summary"
},
"pasharesvalue-f": {
"$ref": "#/components/schemas/summary"
},
"pasharesvalue-s": {
"$ref": "#/components/schemas/summary"
},
"postexpirationexcess": {
"$ref": "#/components/schemas/summary"
},
"postexpirationexcess-c": {
"$ref": "#/components/schemas/summary"
},
"postexpirationexcess-f": {
"$ref": "#/components/schemas/summary"
},
"postexpirationexcess-s": {
"$ref": "#/components/schemas/summary"
},
"postexpirationmargin": {
"$ref": "#/components/schemas/summary"
},
"postexpirationmargin-c": {
"$ref": "#/components/schemas/summary"
},
"postexpirationmargin-f": {
"$ref": "#/components/schemas/summary"
},
"postexpirationmargin-s": {
"$ref": "#/components/schemas/summary"
},
"previousdayequitywithloanvalue": {
"$ref": "#/components/schemas/summary"
},
"previousdayequitywithloanvalue-c": {
"$ref": "#/components/schemas/summary"
},
"previousdayequitywithloanvalue-f": {
"$ref": "#/components/schemas/summary"
},
"previousdayequitywithloanvalue-s": {
"$ref": "#/components/schemas/summary"
},
"segmenttitle-c": {
"$ref": "#/components/schemas/summary"
},
"segmenttitle-f": {
"$ref": "#/components/schemas/summary"
},
"segmenttitle-s": {
"$ref": "#/components/schemas/summary"
},
"totalcashvalue": {
"$ref": "#/components/schemas/summary"
},
"totalcashvalue-c": {
"$ref": "#/components/schemas/summary"
},
"totalcashvalue-f": {
"$ref": "#/components/schemas/summary"
},
"totalcashvalue-s": {
"$ref": "#/components/schemas/summary"
},
"totaldebitcardpendingcharges": {
"$ref": "#/components/schemas/summary"
},
"totaldebitcardpendingcharges-c": {
"$ref": "#/components/schemas/summary"
},
"totaldebitcardpendingcharges-f": {
"$ref": "#/components/schemas/summary"
},
"totaldebitcardpendingcharges-s": {
"$ref": "#/components/schemas/summary"
},
"tradingtype-f": {
"$ref": "#/components/schemas/summary"
},
"tradingtype-s": {
"$ref": "#/components/schemas/summary"
}
}
}
}
}
}
}
}
}
},
"components": {
"requestBodies": {
"Body": {
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {
"acctIds": {
"type": "array",
"items": {
"type": "string",
"description": "account id"
}
}
}
}
}
},
"description": "an array of account ids",
"required": true
}
},
"schemas": {
"futures": {
"type": "array",
"items": {
"type": "object",
"description": "future contract information",
"properties": {
"symbol": {
"type": "string"
},
"conid": {
"type": "integer",
"description": "conid of the future contract"
},
"underlyingConid": {
"type": "integer"
},
"expirationDate": {
"type": "string"
},
"ltd": {
"type": "string",
"description": "last trading day"
}
}
}
},

	    "summary": {
            "type": "object",
            "description": "account information",
            "properties": {
                "total": {
                    "type": "object",
                    "properties": {
                        "chg": {
                            "type": "string",
                            "description": "total change amount"
                        },
                        "rtn": {
                            "type": "string",
                            "description": "change percent"
                        },
                        "incompleteData": {
                            "type": "boolean",
                            "description": "set to true if any external account data is not available for starting or ending date, resulting in potentially unusual total values."
                        },
                        "endVal": {
                            "type": "string"
                        },
                        "startVal": {
                            "type": "string"
                        }
                    }
                },
                "startDate": {
                    "type": "string",
                    "description": "date format-- yyyy-MM-dd"
                },
                "excludedAccounts": {
                    "type": "array",
                    "items": {
                        "type": "object",
                        "properties": {
                            "lastUpdateAttempt": {
                                "type": "string"
                            },
                            "fiName": {
                                "type": "string"
                            },
                            "acctTitle": {
                                "type": "string"
                            },
                            "acctNumAtFI": {
                                "type": "string"
                            },
                            "acctId": {
                                "type": "string"
                            },
                            "lastUpdate": {
                                "type": "string"
                            },
                            "harvestCode": {
                                "type": "integer"
                            },
                            "lastUpdateStatusCode": {
                                "type": "string"
                            },
                            "rc": {
                                "type": "integer"
                            }
                        }
                    }
                },
                "lastSuccessfulUpdate": {
                    "type": "string"
                },
                "accountSummaries": {
                    "type": "array",
                    "items": {
                        "type": "object",
                        "properties": {
                            "chg": {
                                "type": "string"
                            },
                            "hasAccounts": {
                                "type": "string"
                            },
                            "accountTypeName": {
                                "type": "string"
                            },
                            "rtn": {
                                "type": "string"
                            },
                            "endVal": {
                                "type": "string"
                            },
                            "accountTypeCode": {
                                "type": "string"
                            },
                            "startVal": {
                                "type": "string"
                            }
                        }
                    }
                },
                "endDate": {
                    "type": "string"
                },
                "hasExternalAccounts": {
                    "type": "boolean",
                    "description": "indicator of user having configured any external accounts"
                },
                "rc": {
                    "type": "integer"
                },
                "currency": {
                    "type": "string"
                },
                "userId": {
                    "type": "string"
                },
                "pm": {
                    "type": "string"
                },
                "view": {
                    "type": "string"
                },
                "balanceByDate": {
                    "type": "object",
                    "properties": {
                        "series": {
                            "type": "array",
                            "items": {
                                "type": "object",
                                "properties": {
                                    "id": {
                                        "type": "string"
                                    },
                                    "groupId": {
                                        "type": "string"
                                    },
                                    "name": {
                                        "type": "string"
                                    },
                                    "date": {
                                        "type": "array",
                                        "items": {
                                            "type": "array",
                                            "items": {
                                                "type": "number"
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }

	}
}

}
'''

@martin0
Copy link
Author

martin0 commented Jan 19, 2021

Any news on this issue please?

@asyncee
Copy link
Owner

asyncee commented Feb 12, 2021

Currently i can no work on this issue due to personal reasons. I will be happy to merge a PR or you can check another library mentioned in this comment: #19 (comment).

@martin0
Copy link
Author

martin0 commented Feb 12, 2021

Thanks for the update.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants