castToDtomethod to your request. It has one argument which is an instance of SaloonResponse. This method is only run after a successful response has been received from the API. This method should return your data transfer object fully constructed from the response data you received.
fromSaloonmethod however you can use any method of populating your DTO.
dto()method on the response to get the fully constructed DTO.