Bridge

<back to all web services

ETSGetPrice

ETS
The following routes are available for this service:
POST/ETS/Price
import 'package:servicestack/servicestack.dart';
import 'dart:typed_data';

class ETSLinkedVesselsViewModel implements IConvertible
{
    bool? Deleted;
    int? VesselId;
    int? Quantity;
    String? MohaAccount;
    bool? IsQuote;

    ETSLinkedVesselsViewModel({this.Deleted,this.VesselId,this.Quantity,this.MohaAccount,this.IsQuote});
    ETSLinkedVesselsViewModel.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        Deleted = json['Deleted'];
        VesselId = json['VesselId'];
        Quantity = json['Quantity'];
        MohaAccount = json['MohaAccount'];
        IsQuote = json['IsQuote'];
        return this;
    }

    Map<String, dynamic> toJson() => {
        'Deleted': Deleted,
        'VesselId': VesselId,
        'Quantity': Quantity,
        'MohaAccount': MohaAccount,
        'IsQuote': IsQuote
    };

    getTypeName() => "ETSLinkedVesselsViewModel";
    TypeContext? context = _ctx;
}

class ETSGetPrice implements IConvertible
{
    String? OrderType;
    int? Quantity;
    bool? InsertQuote;
    List<ETSLinkedVesselsViewModel>? LinkedVessels;

    ETSGetPrice({this.OrderType,this.Quantity,this.InsertQuote,this.LinkedVessels});
    ETSGetPrice.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        OrderType = json['OrderType'];
        Quantity = json['Quantity'];
        InsertQuote = json['InsertQuote'];
        LinkedVessels = JsonConverters.fromJson(json['LinkedVessels'],'List<ETSLinkedVesselsViewModel>',context!);
        return this;
    }

    Map<String, dynamic> toJson() => {
        'OrderType': OrderType,
        'Quantity': Quantity,
        'InsertQuote': InsertQuote,
        'LinkedVessels': JsonConverters.toJson(LinkedVessels,'List<ETSLinkedVesselsViewModel>',context!)
    };

    getTypeName() => "ETSGetPrice";
    TypeContext? context = _ctx;
}

class GetETSForwardPricesForEntityContactSimpleViewModel implements IConvertible
{
    int? MonthNumber;
    DateTime? StartingDate;
    String? DateForGreyEpoch;
    String? DateForUserInterface;
    int? Over1000;
    double? OurCommissionForOrder;
    double? ExternalFeePerTicket;
    double? ServiceFeeValue;
    String? ServiceFeeDescription;
    double? MarketPrice;
    double? UnitCostPrice;
    String? APIToUse;
    double? SpotAdditionalMargin;
    String? UserContactNumber;
    String? AitherSettlementUUID;

    GetETSForwardPricesForEntityContactSimpleViewModel({this.MonthNumber,this.StartingDate,this.DateForGreyEpoch,this.DateForUserInterface,this.Over1000,this.OurCommissionForOrder,this.ExternalFeePerTicket,this.ServiceFeeValue,this.ServiceFeeDescription,this.MarketPrice,this.UnitCostPrice,this.APIToUse,this.SpotAdditionalMargin,this.UserContactNumber,this.AitherSettlementUUID});
    GetETSForwardPricesForEntityContactSimpleViewModel.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        MonthNumber = json['MonthNumber'];
        StartingDate = JsonConverters.fromJson(json['StartingDate'],'DateTime',context!);
        DateForGreyEpoch = json['DateForGreyEpoch'];
        DateForUserInterface = json['DateForUserInterface'];
        Over1000 = json['Over1000'];
        OurCommissionForOrder = JsonConverters.toDouble(json['OurCommissionForOrder']);
        ExternalFeePerTicket = JsonConverters.toDouble(json['ExternalFeePerTicket']);
        ServiceFeeValue = JsonConverters.toDouble(json['ServiceFeeValue']);
        ServiceFeeDescription = json['ServiceFeeDescription'];
        MarketPrice = JsonConverters.toDouble(json['MarketPrice']);
        UnitCostPrice = JsonConverters.toDouble(json['UnitCostPrice']);
        APIToUse = json['APIToUse'];
        SpotAdditionalMargin = JsonConverters.toDouble(json['SpotAdditionalMargin']);
        UserContactNumber = json['UserContactNumber'];
        AitherSettlementUUID = json['AitherSettlementUUID'];
        return this;
    }

    Map<String, dynamic> toJson() => {
        'MonthNumber': MonthNumber,
        'StartingDate': JsonConverters.toJson(StartingDate,'DateTime',context!),
        'DateForGreyEpoch': DateForGreyEpoch,
        'DateForUserInterface': DateForUserInterface,
        'Over1000': Over1000,
        'OurCommissionForOrder': OurCommissionForOrder,
        'ExternalFeePerTicket': ExternalFeePerTicket,
        'ServiceFeeValue': ServiceFeeValue,
        'ServiceFeeDescription': ServiceFeeDescription,
        'MarketPrice': MarketPrice,
        'UnitCostPrice': UnitCostPrice,
        'APIToUse': APIToUse,
        'SpotAdditionalMargin': SpotAdditionalMargin,
        'UserContactNumber': UserContactNumber,
        'AitherSettlementUUID': AitherSettlementUUID
    };

    getTypeName() => "GetETSForwardPricesForEntityContactSimpleViewModel";
    TypeContext? context = _ctx;
}

class GetETSRegistrationStatusViewModel implements IConvertible
{
    String? Status;
    String? AppliedBy;

    GetETSRegistrationStatusViewModel({this.Status,this.AppliedBy});
    GetETSRegistrationStatusViewModel.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        Status = json['Status'];
        AppliedBy = json['AppliedBy'];
        return this;
    }

    Map<String, dynamic> toJson() => {
        'Status': Status,
        'AppliedBy': AppliedBy
    };

    getTypeName() => "GetETSRegistrationStatusViewModel";
    TypeContext? context = _ctx;
}

class ETSPlaceOrderViewModel implements IConvertible
{
    String? OrderType;
    String? QuoteGuid;
    double? UnitPrice;
    double? Price;
    double? FinancingPrice;
    String? FinancingStatus;
    double? ArrangementFee;
    String? ArrangementFeeDescription;
    String? ETSOrderInfoTextNonFinanced;
    String? ETSOrderInfoTextFinanced;
    String? PaymentType;
    int? Quantity;
    int? OriginalQuantity;
    String? CompanyName;
    String? FullName;
    String? EmailAddress;
    bool? CanPurchaseEUA;
    bool? ThirdParty;
    String? ThirdPartyName;
    double? ExternalFeePerTicket;
    double? OurCommissionForOrder;
    double? EUAPrice;
    double? RawPrice;
    bool? RegenerateQuote;
    String? GetETSMarketHoursMessage;
    bool? IsBridgeClient;
    String? APIToUse;
    String? IoiId;
    String? OfferIoi;
    DateTime? IoiExpiresAt;
    double? SpotAdditionalMargin;
    String? AitherSettlementUUID;
    List<SelectListItem>? GetVessels;
    List<ETSLinkedVesselsViewModel>? LinkedVessels;
    List<GetETSForwardPricesForEntityContactSimpleViewModel>? GetETSForwardPricesForEntityContactSimple;
    GetETSRegistrationStatusViewModel? GetETSRegistrationStatus;

    ETSPlaceOrderViewModel({this.OrderType,this.QuoteGuid,this.UnitPrice,this.Price,this.FinancingPrice,this.FinancingStatus,this.ArrangementFee,this.ArrangementFeeDescription,this.ETSOrderInfoTextNonFinanced,this.ETSOrderInfoTextFinanced,this.PaymentType,this.Quantity,this.OriginalQuantity,this.CompanyName,this.FullName,this.EmailAddress,this.CanPurchaseEUA,this.ThirdParty,this.ThirdPartyName,this.ExternalFeePerTicket,this.OurCommissionForOrder,this.EUAPrice,this.RawPrice,this.RegenerateQuote,this.GetETSMarketHoursMessage,this.IsBridgeClient,this.APIToUse,this.IoiId,this.OfferIoi,this.IoiExpiresAt,this.SpotAdditionalMargin,this.AitherSettlementUUID,this.GetVessels,this.LinkedVessels,this.GetETSForwardPricesForEntityContactSimple,this.GetETSRegistrationStatus});
    ETSPlaceOrderViewModel.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        OrderType = json['OrderType'];
        QuoteGuid = json['QuoteGuid'];
        UnitPrice = JsonConverters.toDouble(json['UnitPrice']);
        Price = JsonConverters.toDouble(json['Price']);
        FinancingPrice = JsonConverters.toDouble(json['FinancingPrice']);
        FinancingStatus = json['FinancingStatus'];
        ArrangementFee = JsonConverters.toDouble(json['ArrangementFee']);
        ArrangementFeeDescription = json['ArrangementFeeDescription'];
        ETSOrderInfoTextNonFinanced = json['ETSOrderInfoTextNonFinanced'];
        ETSOrderInfoTextFinanced = json['ETSOrderInfoTextFinanced'];
        PaymentType = json['PaymentType'];
        Quantity = json['Quantity'];
        OriginalQuantity = json['OriginalQuantity'];
        CompanyName = json['CompanyName'];
        FullName = json['FullName'];
        EmailAddress = json['EmailAddress'];
        CanPurchaseEUA = json['CanPurchaseEUA'];
        ThirdParty = json['ThirdParty'];
        ThirdPartyName = json['ThirdPartyName'];
        ExternalFeePerTicket = JsonConverters.toDouble(json['ExternalFeePerTicket']);
        OurCommissionForOrder = JsonConverters.toDouble(json['OurCommissionForOrder']);
        EUAPrice = JsonConverters.toDouble(json['EUAPrice']);
        RawPrice = JsonConverters.toDouble(json['RawPrice']);
        RegenerateQuote = json['RegenerateQuote'];
        GetETSMarketHoursMessage = json['GetETSMarketHoursMessage'];
        IsBridgeClient = json['IsBridgeClient'];
        APIToUse = json['APIToUse'];
        IoiId = json['IoiId'];
        OfferIoi = json['OfferIoi'];
        IoiExpiresAt = JsonConverters.fromJson(json['IoiExpiresAt'],'DateTime',context!);
        SpotAdditionalMargin = JsonConverters.toDouble(json['SpotAdditionalMargin']);
        AitherSettlementUUID = json['AitherSettlementUUID'];
        GetVessels = JsonConverters.fromJson(json['GetVessels'],'List<SelectListItem>',context!);
        LinkedVessels = JsonConverters.fromJson(json['LinkedVessels'],'List<ETSLinkedVesselsViewModel>',context!);
        GetETSForwardPricesForEntityContactSimple = JsonConverters.fromJson(json['GetETSForwardPricesForEntityContactSimple'],'List<GetETSForwardPricesForEntityContactSimpleViewModel>',context!);
        GetETSRegistrationStatus = JsonConverters.fromJson(json['GetETSRegistrationStatus'],'GetETSRegistrationStatusViewModel',context!);
        return this;
    }

    Map<String, dynamic> toJson() => {
        'OrderType': OrderType,
        'QuoteGuid': QuoteGuid,
        'UnitPrice': UnitPrice,
        'Price': Price,
        'FinancingPrice': FinancingPrice,
        'FinancingStatus': FinancingStatus,
        'ArrangementFee': ArrangementFee,
        'ArrangementFeeDescription': ArrangementFeeDescription,
        'ETSOrderInfoTextNonFinanced': ETSOrderInfoTextNonFinanced,
        'ETSOrderInfoTextFinanced': ETSOrderInfoTextFinanced,
        'PaymentType': PaymentType,
        'Quantity': Quantity,
        'OriginalQuantity': OriginalQuantity,
        'CompanyName': CompanyName,
        'FullName': FullName,
        'EmailAddress': EmailAddress,
        'CanPurchaseEUA': CanPurchaseEUA,
        'ThirdParty': ThirdParty,
        'ThirdPartyName': ThirdPartyName,
        'ExternalFeePerTicket': ExternalFeePerTicket,
        'OurCommissionForOrder': OurCommissionForOrder,
        'EUAPrice': EUAPrice,
        'RawPrice': RawPrice,
        'RegenerateQuote': RegenerateQuote,
        'GetETSMarketHoursMessage': GetETSMarketHoursMessage,
        'IsBridgeClient': IsBridgeClient,
        'APIToUse': APIToUse,
        'IoiId': IoiId,
        'OfferIoi': OfferIoi,
        'IoiExpiresAt': JsonConverters.toJson(IoiExpiresAt,'DateTime',context!),
        'SpotAdditionalMargin': SpotAdditionalMargin,
        'AitherSettlementUUID': AitherSettlementUUID,
        'GetVessels': JsonConverters.toJson(GetVessels,'List<SelectListItem>',context!),
        'LinkedVessels': JsonConverters.toJson(LinkedVessels,'List<ETSLinkedVesselsViewModel>',context!),
        'GetETSForwardPricesForEntityContactSimple': JsonConverters.toJson(GetETSForwardPricesForEntityContactSimple,'List<GetETSForwardPricesForEntityContactSimpleViewModel>',context!),
        'GetETSRegistrationStatus': JsonConverters.toJson(GetETSRegistrationStatus,'GetETSRegistrationStatusViewModel',context!)
    };

    getTypeName() => "ETSPlaceOrderViewModel";
    TypeContext? context = _ctx;
}

TypeContext _ctx = TypeContext(library: 'internal.thebunkerbridge.com', types: <String, TypeInfo> {
    'ETSLinkedVesselsViewModel': TypeInfo(TypeOf.Class, create:() => ETSLinkedVesselsViewModel()),
    'ETSGetPrice': TypeInfo(TypeOf.Class, create:() => ETSGetPrice()),
    'List<ETSLinkedVesselsViewModel>': TypeInfo(TypeOf.Class, create:() => <ETSLinkedVesselsViewModel>[]),
    'GetETSForwardPricesForEntityContactSimpleViewModel': TypeInfo(TypeOf.Class, create:() => GetETSForwardPricesForEntityContactSimpleViewModel()),
    'GetETSRegistrationStatusViewModel': TypeInfo(TypeOf.Class, create:() => GetETSRegistrationStatusViewModel()),
    'ETSPlaceOrderViewModel': TypeInfo(TypeOf.Class, create:() => ETSPlaceOrderViewModel()),
    'List<SelectListItem>': TypeInfo(TypeOf.Class, create:() => <SelectListItem>[]),
    'SelectListItem': TypeInfo(TypeOf.Class, create:() => SelectListItem()),
    'List<GetETSForwardPricesForEntityContactSimpleViewModel>': TypeInfo(TypeOf.Class, create:() => <GetETSForwardPricesForEntityContactSimpleViewModel>[]),
});

Dart ETSGetPrice DTOs

To override the Content-type in your clients, use the HTTP Accept Header, append the .xml suffix or ?format=xml

HTTP + XML

The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.

POST /ETS/Price HTTP/1.1 
Host: internal.thebunkerbridge.com 
Accept: application/xml
Content-Type: application/xml
Content-Length: length

<ETSGetPrice xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Bridge.Private.Api.DTO">
  <InsertQuote>false</InsertQuote>
  <LinkedVessels xmlns:d2p1="http://schemas.datacontract.org/2004/07/Bridge.Core.ViewModels">
    <d2p1:ETSLinkedVesselsViewModel>
      <d2p1:Deleted>false</d2p1:Deleted>
      <d2p1:IsQuote>false</d2p1:IsQuote>
      <d2p1:MohaAccount>String</d2p1:MohaAccount>
      <d2p1:Quantity>0</d2p1:Quantity>
      <d2p1:VesselId>0</d2p1:VesselId>
    </d2p1:ETSLinkedVesselsViewModel>
  </LinkedVessels>
  <OrderType>String</OrderType>
  <Quantity>0</Quantity>
</ETSGetPrice>
HTTP/1.1 200 OK
Content-Type: application/xml
Content-Length: length

<ETSPlaceOrderViewModel xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Bridge.Core.ViewModels">
  <APIToUse>String</APIToUse>
  <AitherSettlementUUID>String</AitherSettlementUUID>
  <ArrangementFee>0</ArrangementFee>
  <ArrangementFeeDescription>String</ArrangementFeeDescription>
  <CanPurchaseEUA>false</CanPurchaseEUA>
  <CompanyName>String</CompanyName>
  <ETSOrderInfoTextFinanced>String</ETSOrderInfoTextFinanced>
  <ETSOrderInfoTextNonFinanced>String</ETSOrderInfoTextNonFinanced>
  <EUAPrice>0</EUAPrice>
  <EmailAddress>String</EmailAddress>
  <ExternalFeePerTicket>0</ExternalFeePerTicket>
  <FinancingPrice>0</FinancingPrice>
  <FinancingStatus>String</FinancingStatus>
  <FullName>String</FullName>
  <GetETSForwardPricesForEntityContactSimple>
    <GetETSForwardPricesForEntityContactSimpleViewModel>
      <APIToUse>String</APIToUse>
      <AitherSettlementUUID>String</AitherSettlementUUID>
      <DateForGreyEpoch>String</DateForGreyEpoch>
      <DateForUserInterface>String</DateForUserInterface>
      <ExternalFeePerTicket>0</ExternalFeePerTicket>
      <MarketPrice>0</MarketPrice>
      <MonthNumber>0</MonthNumber>
      <OurCommissionForOrder>0</OurCommissionForOrder>
      <Over1000>0</Over1000>
      <ServiceFeeDescription>String</ServiceFeeDescription>
      <ServiceFeeValue>0</ServiceFeeValue>
      <SpotAdditionalMargin>0</SpotAdditionalMargin>
      <StartingDate>0001-01-01T00:00:00</StartingDate>
      <UnitCostPrice>0</UnitCostPrice>
      <UserContactNumber>String</UserContactNumber>
    </GetETSForwardPricesForEntityContactSimpleViewModel>
  </GetETSForwardPricesForEntityContactSimple>
  <GetETSMarketHoursMessage>String</GetETSMarketHoursMessage>
  <GetETSRegistrationStatus>
    <AppliedBy>String</AppliedBy>
    <Status>String</Status>
  </GetETSRegistrationStatus>
  <GetVessels xmlns:d2p1="http://schemas.datacontract.org/2004/07/System.Web.Mvc">
    <d2p1:SelectListItem>
      <d2p1:Disabled>false</d2p1:Disabled>
      <d2p1:Group>
        <d2p1:Disabled>false</d2p1:Disabled>
        <d2p1:Name>String</d2p1:Name>
      </d2p1:Group>
      <d2p1:Selected>false</d2p1:Selected>
      <d2p1:Text>String</d2p1:Text>
      <d2p1:Value>String</d2p1:Value>
    </d2p1:SelectListItem>
  </GetVessels>
  <IoiExpiresAt>0001-01-01T00:00:00</IoiExpiresAt>
  <IoiId>String</IoiId>
  <IsBridgeClient>false</IsBridgeClient>
  <LinkedVessels>
    <ETSLinkedVesselsViewModel>
      <Deleted>false</Deleted>
      <IsQuote>false</IsQuote>
      <MohaAccount>String</MohaAccount>
      <Quantity>0</Quantity>
      <VesselId>0</VesselId>
    </ETSLinkedVesselsViewModel>
  </LinkedVessels>
  <OfferIoi>String</OfferIoi>
  <OrderType>String</OrderType>
  <OriginalQuantity>0</OriginalQuantity>
  <OurCommissionForOrder>0</OurCommissionForOrder>
  <PaymentType>String</PaymentType>
  <Price>0</Price>
  <Quantity>0</Quantity>
  <QuoteGuid>00000000-0000-0000-0000-000000000000</QuoteGuid>
  <RawPrice>0</RawPrice>
  <RegenerateQuote>false</RegenerateQuote>
  <SpotAdditionalMargin>0</SpotAdditionalMargin>
  <ThirdParty>false</ThirdParty>
  <ThirdPartyName>String</ThirdPartyName>
  <UnitPrice>0</UnitPrice>
</ETSPlaceOrderViewModel>