Default '_format' for REST resources routes

Created on 24 October 2016, over 8 years ago
Updated 30 November 2023, about 1 year ago

Hello,

I created a RestResource plugin that exposes some data in JSON format. The problem I'm having is that when I access the defined URL for that plugin, I also have to specify the "_format=json" parameter.

Is there a way to alter the default '_format' so that it's json, instead of html, so I can ommit passing it in the URL?

📌 Task
Status

Closed: duplicate

Version

8.3 ⚰️

Component
REST 

Last updated 10 days ago

Created by

🇷🇴Romania vdanielpop

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

  • First commit to issue fork.
Production build 0.71.5 2024