如何将IHttpApi接口定义中的参数传给TokenProvider

Open
#279 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
5/5
Estimated time
Over a week
Newbie friendliness
25/100
Issue type
Feature
Clarity
Needs clarification
Activity status
Stale
Tech stack
csharp

Research direction

Start by tracing how IHttpApi parameters are passed into ApiRequestContext and ApiParametersContext, and how TokenProvider is resolved through dependency injection. Define whether appName can reach TokenProvider for dynamic token selection, then confirm the supported behavior and its completion criteria with the maintainers.

Written by the indexing model from the issue text.

Description

question 等待反馈(needs feedback)

需求是需要根据appName参数动态切换token。
目前是想通过在TokenProvider中获取参数值后去请求token,但是ApiRequestContext和ApiParametersContext都无法通过依赖注入获取到。

需要如何实现此功能

Dominant language
C#
Stars
2.1k
Forks
445
PR merge metrics
No merged PRs in 30d

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from dotnetcore/WebApiClient

All issues in dotnetcore/WebApiClient

Similar issues

More C# issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.