astral-api/Astral.ApiServer/Controllers/OAuthController.cs
2024-12-11 22:12:53 +00:00

29 lines
881 B
C#

// <copyright file="OAuthController.cs" company="alveus.dev">
// Copyright (c) alveus.dev. All rights reserved. Licensed under the MIT License.
// </copyright>
using Astral.ApiServer.Models;
using Microsoft.AspNetCore.Authorization;
using Microsoft.AspNetCore.Mvc;
namespace Astral.ApiServer.Controllers;
/// <summary>
/// OAuth authentication controller.
/// </summary>
[Produces("application/json")]
[Consumes("application/x-www-form-urlencoded")]
[Route("oauth")]
public class OAuthController : ControllerBase
{
/// <summary>
/// Grant token request.
/// </summary>
/// <param name="tokenGrantRequest">Instance of <see cref="TokenGrantRequestModel"/>.</param>
[HttpPost("token")]
[AllowAnonymous]
public Task<IActionResult> GrantToken([FromForm] TokenGrantRequestModel tokenGrantRequest)
{
throw new NotImplementedException();
}
}