summaryrefslogtreecommitdiffstats
path: root/samples/OAuthServiceProvider/Code/RequestScopedTokenMessage.cs
blob: 984d6830217bed71ac5551bea0530c5637c8de8d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
namespace OAuthServiceProvider.Code {
	using System;
	using DotNetOpenAuth.Messaging;
	using DotNetOpenAuth.OAuth.Messages;

	/// <summary>
	/// A custom web app version of the message sent to request an unauthorized token.
	/// </summary>
	public class RequestScopedTokenMessage : UnauthorizedTokenRequest {
		/// <summary>
		/// Initializes a new instance of the <see cref="RequestScopedTokenMessage"/> class.
		/// </summary>
		/// <param name="endpoint">The endpoint that will receive the message.</param>
		/// <param name="version">The OAuth version.</param>
		public RequestScopedTokenMessage(MessageReceivingEndpoint endpoint, Version version)
			: base(endpoint, version) {
		}

		/// <summary>
		/// Gets or sets the scope of the access being requested.
		/// </summary>
		[MessagePart("scope", IsRequired = true)]
		public string Scope { get; set; }
	}
}