Documentation of the CarRentalAgentService

CarRentalAgentService. Method 

Retrieves the set of supported Currencies.

public CurrenciesResponse (
   CurrenciesRequest request
);

Parameters

CurrenciesRequest
A CurrenciesRequest containing the nessessary request data.

Return Value

A CurrenciesResponse containing all available Currencies.

Remarks

Use this method to get all currencies which are supported by this Web Service.

A supported currency is a currency for which you are able to requestRates or perform a Reservation. The default currency is Euro (EUR).

For a RatesRequest for example, you can specify a CurrencyCode, which is the three letter ISO 4217 code defined in Code. Using this method prior calling GetRates, you can ensure that the preferred currency of the customer is supported for car rentals at Sunny Cars.

List Of defined call-variants

parameters GetCurrenciesP1
token required


Description : This variant returns all currencies available at CarRentalAgentService.

List Of Errors Returned

Error Code Description
E_INTERNAL_SERVICE An internal service error occured during the process.
E_TICKET_TOKEN_INVALID The provided token is invalid.

This error occurs if:

  • The token is in invalid format.
  • The token is expired.
  • The token was not found.

E_CURRENCY_NOT_FOUND No currencies are currently supported by service. Default currency is used.
E_REQUEST_INVALID The performed request is invalid or malformed.

Example

Example: Loading all supported currencies.

[C#]
CurrenciesRequest rq = new CurrenciesRequest();
rq.Ticket = this.serviceTicket;

CurrenciesResponse rs = this.service.GetCurrencies(rq);

foreach (Currency cur in rs.Currency)
{
    Console.WriteLine("Currency {0} supported. Code: {1}, Id: {2}", cur.Name, cur.Code, cur.Id);
}

See Also

CarRentalAgentService Class | SunnyCars.Services.Osi.WsReservation Namespace