Skip to content

Raw Requests

Arun Prakash edited this page Mar 17, 2024 · 1 revision

πŸš€ Raw Requests

Send raw requests to handle responses outside of traditional model classes. This enables integration with database solutions for caching or storing responses.

final WordpressRawResponse response = await client.posts.listRaw(
    ListPostRequest(
      perPage: 5,
      order: Order.asc,
    ),
);

WordpressRawResponse instance contains the raw content received from the API call along with numerous other details such as the headers and time taken as duration.

You can then manually parse the content to your custom model class as required for the database solution which you opted for your application.