Date: Thu, 28 Mar 2024 20:32:20 +0000 (UTC) Message-ID: <43784325.53.1711657940969@d87277c075a4> Subject: Exported From Confluence MIME-Version: 1.0 Content-Type: multipart/related; boundary="----=_Part_52_1204355366.1711657940968" ------=_Part_52_1204355366.1711657940968 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Content-Location: file:///C:/exported.html
Name |
Type |
Description |
Mandatory |
Available from version |
---|---|---|---|---|
StartDate |
DateTime |
Filter by start date |
True |
|
EndDate |
DateTime |
Filter by end date |
True |
|
DisplayCurrencyCode |
string |
Enter what currency in ISO-format that the results should be retreived i= n |
True |
|
AccountDimensionKey |
string |
Filter by dimension key ("T" for traded, "S" for settled) |
True |
|
Accounts |
Guid[]? |
Filter by BfsId of accounts |
|
|
Assets |
Guid[]? |
Filter by BfsId of assets |
|
|
IncludeZeroes |
bool |
If set to yes, empty and negative positions will be included. Defaultval= ue is false if not supplied |
|
2.20 |
AssetTypeKeys |
string[] |
Filter by array of asset type keys (Cash or GenericInstrument) <= /td> |
|
2.38 |
InstrumentTypes |
int[] |
Filter by array of instrument types |
|
2.38 |
Name |
Type |
Description |
Available from version |
---|---|---|---|
Account |
Guid |
BfsId of the account |
|
AccountNo |
string |
The account number for the position |
|
Asset |
Guid |
BfsId of the instrument |
|
BalanceDate |
DateTime |
The balance date of the position |
|
Amount |
decimal |
The amount of the position |
|
AccountDimensionKey |
string |
The dimension of the positon, "T" for traded and "S" for settled |
|
Price |
double |
Price of instrument when position was acquired. |
|
FxRate |
double |
This is the exchange rate used= if DisplayCurrency is used. If the currency of the position is EUR and the= DisplayCurrency is set to USD this is the exchange rate between EUR and US= D |
|
BaseRate |
double |
This is the exchange rate betw= een the currency of the instrument and the base currency of the account. |
|
MarketValue |
double |
The market value for the position. |
|
MarketValueAccountCurrency |
double |
The market value for the position in the account currency. If instrument= and account has the same currency this value is the same as MarketValue ab= ove. |
|
MarketValueDisplayCurrency |
double |
The market value for the position according to display currency. |
|
DisplayRate |
double |
The exchan= ge rate between the position instrument currency and the DisplayCurrencyCode |
|
AssetType |
string |
Type of asset |
|
DisplayPercentagePrice |
Bool |
If price is in persentage of MinimumLotSize |
|
//Use the= GetHistoricPositions var client =3D new BFSServiceReference.bfsapiSoapClient(); var credentials =3D new BFSServiceReference.Credentials() { UserName =3D bfsusername, //Username of administrative user in your ins= tance of BFS Password =3D bfspassword, //Password of the administrative user in your= instance of BFS }; var positions =3D client.GetHistoricPositions(new BFSServiceReference.GetHi= storicPositionRequest() { Credentials =3D credentials, identify =3D bfsidentifier, //Identifier is a unique token for your ins= tance of BFS=20 Args =3D new GetHistoricPositionArgs() { StartDate =3D new DateTime(2016, 04, 01, 0, 0, 0, DateTimeKind.Utc)= , EndDate =3D new DateTime(2016, 04, 20, 0, 0, 0, DateTimeKind.Utc), DisplayCurrencyCode =3D "USD", AccountDimensionKey =3D "T", Accounts =3D new[] { =09=09=09new Guid("40045f57-9914-41d2-9ffd-a33a59de10c9"), } }, Fields =3D new BFSServiceReference.GetHistoricPositionFields() { Account =3D true, AccountNo =3D true, AccountDimensionKey =3D true, =20 Amount =3D true, Asset =3D true, AssetType =3D true, BalanceDate =3D true, BaseRate =3D true, DisplayCurrencyCode =3D true, DisplayRate =3D true, FxRate =3D true, MarketValue =3D true, MarketValueAccountCurrency =3D true, MarketValueDisplayCurrency =3D true, Price =3D true }, }); foreach (var c in positions.Result) { Console.WriteLine(c.Account + ", "=20 + c.AccountNo + ", "=20 + c.AccountDimensionKey + ", "=20 + c.Amount + ", " + c.Asset + ", " + c.AssetType + ", " + c.BalanceDate + ", " + c.BaseRate + ", " + c.DisplayCurrencyCode + ", " // + c.FxRate + ", " + c.MarketValue + ", " + c.MarketValueAccountCurrency + ", " + c.MarketValueDisplayCurrency + ", " // + c.Price + ", " + c.MarketValue); }
<?xml= version=3D"1.0" encoding=3D"utf-8"?> <soap:Envelope xmlns:soap=3D"http://schemas.xmlsoap.org/soap/envelope/" = xmlns:xsi=3D"http://www.w3.org/2001/XMLSchema-instance" xmlns:tns=3D"http:= //tempuri.org/" xmlns:s1=3D"http://microsoft.com/wsdl/types/" xmlns:tm=3D"h= ttp://microsoft.com/wsdl/mime/textMatching/"> <soap:Body> <GetHistoricPositions xmlns=3D"http://tempuri.org/"> <req> <Credentials> <UserName>{{username}}</UserName> <Password>{{password}}</Password> </Credentials> <identify>{{identifier}}</identify> <Args> <Accounts> <guid>[Guid of the account]</guid> <guid>[Guid of the account]</guid> = =20 </Accounts> <StartDate>[The start date]</StartDate> <EndDate>[The end date]</EndDate> <AccountDimensionKey>[The account dimension T or = S (Trade/Settle)]</AccountDimensionKey> <DisplayCurrencyCode>[The currency code. For exam= ple USD]</DisplayCurrencyCode> </Args> <Fields> <BrickId>true</BrickId> <Asset>true</Asset> <CreatedDate>true</CreatedDate> <Account>true</Account> <AccountNo>true</AccountNo> <BalanceDate>true</BalanceDate> <Amount>true</Amount> <AccountDimensionKey>true</AccountDimensionKey= > <Price>true</Price> <FxRate>true</FxRate> <BaseRate>true</BaseRate> <MarketValue>true</MarketValue> <MarketValueAccountCurrency>true</MarketValueA= ccountCurrency> <MarketValueDisplayCurrency>true</MarketValueD= isplayCurrency> <DisplayRate>true</DisplayRate> <AssetType>true</AssetType> <DisplayPercentagePrice>false</DisplayPercenta= gePrice> <IncludeZeroes>true</IncludeZeroes> </Fields> </req> </GetHistoricPositions> </soap:Body> </soap:Envelope>
Create a blog post to share news and announcements with your team and co= mpany.