astral-api/Astral.ApiServer/Models/Requests/TokenGrantRequestModel.cs

44 lines
1 KiB
C#
Raw Normal View History

2024-12-11 23:12:53 +01:00
// <copyright file="TokenGrantRequestModel.cs" company="alveus.dev">
// Copyright (c) alveus.dev. All rights reserved. Licensed under the MIT License.
// </copyright>
using Microsoft.AspNetCore.Mvc;
2024-12-15 17:06:14 +01:00
namespace Astral.ApiServer.Models.Requests;
2024-12-11 23:12:53 +01:00
/// <summary>
/// Oauth token grant request.
/// </summary>
public class TokenGrantRequestModel
{
/// <summary>
/// The grant type of the request.
/// </summary>
[FromForm(Name = "grant_type")]
public string GrantType { get; set; }
/// <summary>
/// Refresh token.
/// </summary>
[FromForm(Name = "refresh_token")]
public string RefreshToken { get; set; }
/// <summary>
/// Username.
/// </summary>
[FromForm(Name = "username")]
public string Username { get; set; }
/// <summary>
/// Password.
/// </summary>
[FromForm(Name = "password")]
public string Password { get; set; }
/// <summary>
/// Scope.
/// </summary>
[FromForm(Name = "scope")]
public string Scope { get; set; }
}