@@ -215,7 +215,7 @@ autoconfigure the HTTP client based on the requested URL:
215
215
http_client :
216
216
scoped_clients :
217
217
# only requests matching scope will use these options
218
- github :
218
+ github.client :
219
219
scope : ' https://api\.github\.com'
220
220
headers :
221
221
Accept : ' application/vnd.github.v3+json'
@@ -224,7 +224,7 @@ autoconfigure the HTTP client based on the requested URL:
224
224
225
225
# using base_uri, relative URLs (e.g. request("GET", "/repos/symfony/symfony-docs"))
226
226
# will default to these options
227
- github :
227
+ github.client :
228
228
base_uri : ' https://api.github.com'
229
229
headers :
230
230
Accept : ' application/vnd.github.v3+json'
@@ -245,7 +245,7 @@ autoconfigure the HTTP client based on the requested URL:
245
245
<framework : config >
246
246
<framework : http-client >
247
247
<!-- only requests matching scope will use these options -->
248
- <framework : scoped-client name =" github"
248
+ <framework : scoped-client name =" github.client "
249
249
scope =" https://api\.github\.com"
250
250
>
251
251
<framework : header name =" Accept" >application/vnd.github.v3+json</framework : header >
@@ -254,7 +254,7 @@ autoconfigure the HTTP client based on the requested URL:
254
254
255
255
<!-- using base-uri, relative URLs (e.g. request("GET", "/repos/symfony/symfony-docs"))
256
256
will default to these options -->
257
- <framework : scoped-client name =" github"
257
+ <framework : scoped-client name =" github.client "
258
258
base-uri =" https://api.github.com"
259
259
>
260
260
<framework : header name =" Accept" >application/vnd.github.v3+json</framework : header >
@@ -271,7 +271,7 @@ autoconfigure the HTTP client based on the requested URL:
271
271
272
272
return static function (FrameworkConfig $framework) {
273
273
// only requests matching scope will use these options
274
- $framework->httpClient()->scopedClient('github')
274
+ $framework->httpClient()->scopedClient('github.client ')
275
275
->scope('https://api\.github\.com')
276
276
->header('Accept', 'application/vnd.github.v3+json')
277
277
->header('Authorization', 'token %env(GITHUB_API_TOKEN)%')
@@ -280,7 +280,7 @@ autoconfigure the HTTP client based on the requested URL:
280
280
281
281
// using base_url, relative URLs (e.g. request("GET", "/repos/symfony/symfony-docs"))
282
282
// will default to these options
283
- $framework->httpClient()->scopedClient('github')
283
+ $framework->httpClient()->scopedClient('github.client ')
284
284
->baseUri('https://api.github.com')
285
285
->header('Accept', 'application/vnd.github.v3+json')
286
286
->header('Authorization', 'token %env(GITHUB_API_TOKEN)%')
@@ -323,8 +323,8 @@ Each client has a unique service named after its configuration.
323
323
324
324
Each scoped client also defines a corresponding named autowiring alias.
325
325
If you use for example
326
- ``Symfony\Contracts\HttpClient\HttpClientInterface $myApiClient ``
327
- as the type and name of an argument, autowiring will inject the ``my_api .client ``
326
+ ``Symfony\Contracts\HttpClient\HttpClientInterface $githubClient ``
327
+ as the type and name of an argument, autowiring will inject the ``github .client ``
328
328
service into your autowired classes.
329
329
330
330
.. note ::
0 commit comments