-
Notifications
You must be signed in to change notification settings - Fork 551
Expand file tree
/
Copy pathEtsyAuthenticationConstants.cs
More file actions
94 lines (70 loc) · 3.71 KB
/
EtsyAuthenticationConstants.cs
File metadata and controls
94 lines (70 loc) · 3.71 KB
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
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
/*
* Licensed under the Apache License, Version 2.0 (http://www.apache.org/licenses/LICENSE-2.0)
* See https://github.com/aspnet-contrib/AspNet.Security.OAuth.Providers
* for more information concerning the license and the contributors participating to this project.
*/
namespace AspNet.Security.OAuth.Etsy;
/// <summary>
/// Contains constants specific to the <see cref="EtsyAuthenticationHandler"/>.
/// </summary>
public static class EtsyAuthenticationConstants
{
/// <summary>
/// Contains claim type constants specific to Etsy authentication.
/// </summary>
public static class Claims
{
/// <summary>The claim type for the user's Etsy user ID.</summary>
public static readonly string UserId = "urn:etsy:user_id";
/// <summary>The claim type for the user's Etsy shop ID.</summary>
public static readonly string ShopId = "urn:etsy:shop_id";
/// <summary>The claim type for the user's profile image URL.</summary>
public static readonly string ImageUrl = "urn:etsy:image_url";
}
/// <summary>
/// Contains <see href="https://developers.etsy.com/documentation/reference#section/Authentication/oauth2">Etsy OAuth Scopes</see> constants for Etsy authentication.
/// </summary>
public static class Scopes
{
/// <summary>See billing and shipping addresses</summary>
public static readonly string AddressRead = "address_r";
/// <summary>Update billing and shipping addresses</summary>
public static readonly string AddressWrite = "address_w";
/// <summary>See all billing statement data</summary>
public static readonly string BillingRead = "billing_r";
/// <summary>Read shopping carts</summary>
public static readonly string CartRead = "cart_r";
/// <summary>Add/Remove from shopping carts</summary>
public static readonly string CartWrite = "cart_w";
/// <summary>Read a user profile</summary>
public static readonly string EmailRead = "email_r";
/// <summary>See private favorites</summary>
public static readonly string FavoritesRead = "favorites_r";
/// <summary>Add/Remove favorites</summary>
public static readonly string FavoritesWrite = "favorites_w";
/// <summary>See purchase info in feedback</summary>
public static readonly string FeedbackRead = "feedback_r";
/// <summary>Delete listings</summary>
public static readonly string ListingsDelete = "listings_d";
/// <summary>See all listings (including expired etc)</summary>
public static readonly string ListingsRead = "listings_r";
/// <summary>Create/Edit listings</summary>
public static readonly string ListingsWrite = "listings_w";
/// <summary>See all profile data</summary>
public static readonly string ProfileRead = "profile_r";
/// <summary>Update user profile, avatar, etc</summary>
public static readonly string ProfileWrite = "profile_w";
/// <summary>See recommended listings</summary>
public static readonly string RecommendRead = "recommend_r";
/// <summary>Accept/Reject recommended listings</summary>
public static readonly string RecommendWrite = "recommend_w";
/// <summary>See private shop info</summary>
public static readonly string ShopsRead = "shops_r";
/// <summary>Update shop</summary>
public static readonly string ShopsWrite = "shops_w";
/// <summary>See all checkout/payment data</summary>
public static readonly string TransactionsRead = "transactions_r";
/// <summary>Update receipts</summary>
public static readonly string TransactionsWrite = "transactions_w";
}
}