Error information
<MethodNotAllowed>
<error>method_not_allowed</error>
<error_description>Request method 'GET' not supported</error_description>
</MethodNotAllowed>
39 is a single quotation mark
Why
Only post is supported by default
Solutions
download and install postman tool (or other post tools) and use post to call
method of adding get to code
@Configuration
public class OAuthSecurityConfig extends AuthorizationServerConfigurerAdapter {
...
@Override
public void configure(AuthorizationServerEndpointsConfigurer endpoints) throws Exception {
...
endpoints.allowedTokenEndpointRequestMethods(HttpMethod.GET, HttpMethod.POST);// add get method
...
endpoints.tokenServices(tokenServices);
}
...
Similar Posts:
- [Solved] oauth2(spring security) Error: method_not_allowed(Request method ‘GET’ not supported)
- Springboot2 oauth2 Error: Possible CSRF detected – state parameter was required but no state could
- [Solved] java.lang.IllegalArgumentException: There is no PasswordEncoder mapped for the id “null”
- [Solved] failure to inject AuthenticationManager directly Error
- Problems of bad credentials, encoded password does not look like bcrypt in spring-cloud-oauth2 upgrade
- [Solved] Json.Net Error: Error getting value from ‘ScopeId’ on ‘System.Net.IPAddress’
- [Solved] Json.Net – Error getting value from ‘ScopeId’ on ‘System.Net.IPAddress’
- An error is reported when swagger is used: failed to load API definition
- [Solved] Using JDK dynamic agent to customize SPI Error: UndeclaredThrowableException