Skip to content

Commit f7dec26

Browse files
adriendupuisadamwojs
authored andcommitted
ContentLoadByIdController: Rm Accept header parameter
1 parent 376a23f commit f7dec26

File tree

1 file changed

+4
-20
lines changed

1 file changed

+4
-20
lines changed

src/lib/Server/Controller/Content/ContentLoadByIdController.php

Lines changed: 4 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -20,29 +20,13 @@
2020
uriTemplate: '/content/objects/{contentId}',
2121
openapi: new Model\Operation(
2222
summary: 'Load content',
23-
description: 'Loads the content item for the given ID. Depending on the Accept header the current version is embedded (i.e. the current published version or if it does not exist, the draft of the authenticated user).',
23+
description: 'Loads the content item for the given ID. Depending on the Accept header the current version is embedded (i.e. the current published version or if it does not exist, the draft of the authenticated user).
24+
* Content - If set, all information for the content item including the embedded current version is returned in XML or JSON format.
25+
* ContentInfo - If set, all information for the content item (excluding the current version) is returned in XML or JSON format.',
2426
tags: [
2527
'Objects',
2628
],
2729
parameters: [
28-
new Model\Parameter(
29-
name: 'Accept',
30-
in: 'header',
31-
required: true,
32-
description: '
33-
* Content - If set, all information for the content item including the embedded current version is returned in XML or JSON format.
34-
* ContentInfo - If set, all information for the content item (excluding the current version) is returned in XML or JSON format.
35-
',
36-
schema: [
37-
'type' => 'string',
38-
'enum' => [
39-
'application/vnd.ibexa.api.Content+xml',
40-
'application/vnd.ibexa.api.Content+json',
41-
'application/vnd.ibexa.api.ContentInfo+xml',
42-
'application/vnd.ibexa.api.ContentInfo+json',
43-
],
44-
],
45-
),
4630
new Model\Parameter(
4731
name: 'If-None-Match',
4832
in: 'header',
@@ -80,12 +64,12 @@
8064
'schema' => [
8165
'$ref' => '#/components/schemas/ContentInfo',
8266
],
67+
'x-ibexa-example-file' => '@IbexaRestBundle/Resources/api_platform/examples/content/objects/content_id/PATCH/ContentInfo.xml.example',
8368
],
8469
'application/vnd.ibexa.api.ContentInfo+json' => [
8570
'schema' => [
8671
'$ref' => '#/components/schemas/ContentInfoWrapper',
8772
],
88-
'x-ibexa-example-file' => '@IbexaRestBundle/Resources/api_platform/examples/content/objects/content_id/PATCH/ContentInfo.xml.example',
8973
],
9074
],
9175
],

0 commit comments

Comments
 (0)