Fix the REST ressource for getting the latest localisation of a user.
[Project_proches_de_moi-server.git] / config / packages / fos_rest.yaml
CommitLineData
dec6d031 1# Read the documentation: https://symfony.com/doc/master/bundles/FOSRestBundle/index.html
98cb0edc 2fos_rest:
dec6d031
JB
3# param_fetcher_listener: true
4# allowed_methods_listener: true
5# routing_loader: true
6# view:
7# view_response_listener: true
8# exception:
9# codes:
10# App\Exception\MyException: 403
11# messages:
12# App\Exception\MyException: Forbidden area.
13# format_listener:
14# rules:
15# - { path: ^/api, prefer_extension: true, fallback_format: json, priorities: [ json, html ] }
9b636c8d
JB
16 routing_loader:
17 include_format: false
18 view:
19 view_response_listener: true
20 mime_types:
21 json: ['application/json', 'application/json;version=1.0', 'application/json;version=2.0']
22 format_listener:
23 rules:
24 - { path: '^/api', priorities: ['json'], fallback_format: 'json' }
25 body_listener:
26 enabled: true
f0640a52
JB
27 body_converter:
28 enabled: true
9b636c8d
JB
29 versioning:
30 enabled: true
31 resolvers:
32 media_type: # Accept header
33 enabled: true
34 regex: '/(v|version)=(?P<version>[0-9\.]+)/'
787fc3b7
JB
35 serializer:
36 serialize_null: true