App Context API for C# SDK
This page describes App Context (formerly Objects v2). To upgrade from Objects v1, refer to the migration guide.
App Context provides easy-to-use, serverless storage for user and channel data that you need to build reliable, scalable applications. Use App Context to store metadata about your application users and channels, and their membership associations, without the need to run your own databases.
PubNub triggers events when object data is set, updated, or removed. Setting the same data that already exists does not trigger an event. Clients can receive these events in real time and update the front end accordingly.
Starting a new app? Use DataSync
DataSync is the successor to App Context. It covers the same users, channels, and memberships, and adds typed schemas, JSON Patch updates with ETags, field-level projections, and per-class expiry. Refer to the feature-by-feature comparison for details.
DataSync is currently available to new accounts and to accounts that are not actively using App Context. If your keysets already use App Context, keep using it for now. App Context remains fully supported.
Request execution
Use try/catch when working with the C# SDK.
If a request has invalid parameters (for example, a missing required field), the SDK throws an exception. If the request reaches the server but fails (server error or network issue), the error details are available in the returned status.
1try
2{
3 PNResult<PNPublishResult> publishResponse = await pubnub.Publish()
4 .Message("Why do Java developers wear glasses? Because they can't C#.")
5 .Channel("my_channel")
6 .ExecuteAsync();
7
8 PNStatus status = publishResponse.Status;
9
10 Console.WriteLine("Server status code : " + status.StatusCode.ToString());
11}
12catch (Exception ex)
13{
14 Console.WriteLine($"Request can't be executed due to error: {ex.Message}");
15}
User
Get metadata for all users
Returns a paginated list of UUID Metadata objects, optionally including the custom data object for each.
Required keyset configuration
Method(s)
To Get All UUID Metadata you can use the following method(s) in the C# SDK:
1pubnub.GetAllUuidMetadata()
2 .IncludeCustom(bool)
3 .IncludeCount(bool)
4 .Page(PNPageObject)
5 .Sort(List<string>)
6 .Filter(string)
7 .Limit(int)
IncludeCustom#- Whether to include the
Customobject in the response. IncludeCount#- Whether to include the total count in the paginated response. Default is false.
Page#- Cursor-based pagination.
Sort#- Sort by
id,name,updatedwithasc/desc(for example,{name: 'asc'}). Limit#- Number of objects to return. Default/Max: 100.
Sample code
1using PubnubApi;
2
3// Configuration
4PNConfiguration pnConfiguration = new PNConfiguration(new UserId("myUniqueUserId"))
5{
6 SubscribeKey = "demo",
7 PublishKey = "demo",
8 Secure = true
9};
10
11// Initialize PubNub
12Pubnub pubnub = new Pubnub(pnConfiguration);
13
14try
15{
show all 36 linesResponse
1{
2 "Uuids": [
3 {
4 "Uuid": "uuid-1",
5 "Name": "John Doe",
6 "Email": "jack@twitter.com",
7 "ExternalId": null,
8 "ProfileUrl": null,
9 "Custom": null,
10 "Updated": "2020-06-17T16:28:14.060718Z"
11 },
12 {
13 "Uuid": "uuid-2",
14 "Name": "Bob Cat",
15 "Email": "bobc@example.com",
show all 29 linesGet user metadata
Returns metadata for the specified UUID, optionally including the custom data object for each.
Method(s)
To Get UUID Metadata you can use the following method(s) in the C# SDK:
1pubnub.GetUuidMetadata()
2 .Uuid(string)
3 .IncludeCustom(bool)
Sample code
1using PubnubApi;
2
3// Configuration
4PNConfiguration pnConfiguration = new PNConfiguration(new UserId("myUniqueUserId"))
5{
6 SubscribeKey = "demo",
7 PublishKey = "demo",
8 Secure = true
9};
10
11// Initialize PubNub
12Pubnub pubnub = new Pubnub(pnConfiguration);
13
14// Get Metadata for UUID set in the pubnub instance
15PNResult<PNGetUuidMetadataResult> getUuidSetMetadataResponse = await pubnub.GetUuidMetadata()
show all 25 linesResponse
1{
2 "Uuid": "uuid-1",
3 "Name": "John Doe",
4 "Email": "jack@twitter.com",
5 "ExternalId": null,
6 "ProfileUrl": null,
7 "Custom": null,
8 "Updated": "2020-06-17T16:28:14.060718Z"
9}
Set user metadata
Unsupported partial updates of custom metadata
The value of the custom metadata parameter sent in this method always overwrites the value stored on PubNub servers. If you want to add new custom data to an existing one, you must:
- Get the existing metadata and store it locally.
- Append the new custom metadata to the existing one.
- Set the entire updated custom object.
Set metadata for a UUID in the database, optionally including the custom data object for each.
Method(s)
To Set UUID Metadata you can use the following method(s) in the C# SDK:
1pubnub.SetUuidMetadata()
2 .Uuid(string)
3 .Name(string)
4 .Email(string)
5 .ExternalId(string)
6 .ProfileUrl(string)
7 .Custom(Dictionary<string, object>)
8 .IncludeCustom(bool)
9 .IfMatchesEtag(string)
Uuidrequired#- Unique user identifier (UUID). If not supplied, the current user's UUID is used.
Namerequired#- Display name for the user.
Email#- The user's email address.
ExternalId#- User's identifier in an external system.
ProfileUrl#- The URL of the user's profile picture.
Custom#- Custom JSON values. Can be strings, numbers, or booleans. Filtering by
Customisn’t supported. IncludeCustom#- Whether to include the
Customobject in the response. IfMatchesEtag#- Use the eTag from an applicable get metadata call to ensure updates only apply if the object hasn’t changed. If the eTags differ, the server returns HTTP 412.
API limits
To learn about the maximum length of parameters used to set user metadata, refer to REST API docs.
Sample code
1using PubnubApi;
2
3// Configuration
4PNConfiguration pnConfiguration = new PNConfiguration(new UserId("myUniqueUserId"))
5{
6 SubscribeKey = "demo",
7 PublishKey = "demo",
8 Secure = true
9};
10
11// Initialize PubNub
12Pubnub pubnub = new Pubnub(pnConfiguration);
13
14// Set Metadata for UUID set in the pubnub instance
15PNResult<PNSetUuidMetadataResult> setUuidMetadataResponse = await pubnub.SetUuidMetadata()
show all 21 linesResponse
1{
2 "Uuid": "uuid-1",
3 "Name": "John Doe",
4 "Email": "jack@twitter.com",
5 "ExternalId": null,
6 "ProfileUrl": null,
7 "Custom": null,
8 "Updated": "2020-06-17T16:28:14.060718Z"
9}
Remove user metadata
Removes the metadata from a specified UUID.
Method(s)
To Remove UUID Metadata you can use the following method(s) in the C# SDK:
1pubnub.RemoveUuidMetadata()
2 .Uuid(string)
Uuidrequired#- Unique user identifier (UUID). If not supplied, the current user's UUID is used.
Sample code
1using PubnubApi;
2
3// Configuration
4PNConfiguration pnConfiguration = new PNConfiguration(new UserId("myUniqueUserId"))
5{
6 SubscribeKey = "demo",
7 PublishKey = "demo",
8 Secure = true
9};
10
11// Initialize PubNub
12Pubnub pubnub = new Pubnub(pnConfiguration);
13
14// Remove Metadata for UUID set in the pubnub instance
15PNResult<PNRemoveUuidMetadataResult> removeUuidMetadataResponse = await pubnub.RemoveUuidMetadata()
show all 18 linesResponse
1{}
Channel
Get metadata for all channels
Returns a paginated list of Channel Metadata objects, optionally including the custom data object for each.
Required keyset configuration
Method(s)
To Get All Channel Metadata you can use the following method(s) in the C# SDK:
1pubnub.GetAllChannelMetadata()
2 .IncludeCustom(bool)
3 .IncludeCount(bool)
4 .Page(PNPageObject)
5 .Sort(List<string>)
6 .Filter(string)
Sample code
1using PubnubApi;
2
3// Configuration
4PNConfiguration pnConfiguration = new PNConfiguration(new UserId("myUniqueUserId"))
5{
6 SubscribeKey = "demo",
7 PublishKey = "demo",
8 Secure = true
9};
10
11// Initialize PubNub
12Pubnub pubnub = new Pubnub(pnConfiguration);
13
14PNResult<PNGetAllChannelMetadataResult> getAllChannelMetadataResponse = await pubnub.GetAllChannelMetadata()
15 .IncludeCount(true)
show all 20 linesResponse
1{
2 "Channels": [
3 {
4 "Channel": "my-channel",
5 "Name": "My channel",
6 "Description": "A channel that is mine",
7 "Custom": null,
8 "Updated": "2020-06-17T16:52:19.562469Z"
9 },
10 {
11 "Channel": "main",
12 "Name": "Main channel",
13 "Description": "The main channel",
14 "Custom": {
15 "public": true,
show all 26 linesGet channel metadata
Returns metadata for the specified Channel, optionally including the custom data object for each.
Method(s)
To Get Channel Metadata you can use the following method(s) in the C# SDK:
1pubnub.GetChannelMetadata()
2 .Channel(string)
3 .IncludeCustom(bool)
Sample code
1using PubnubApi;
2
3// Configuration
4PNConfiguration pnConfiguration = new PNConfiguration(new UserId("myUniqueUserId"))
5{
6 SubscribeKey = "demo",
7 PublishKey = "demo",
8 Secure = true
9};
10
11// Initialize PubNub
12Pubnub pubnub = new Pubnub(pnConfiguration);
13
14// Get Metadata for a specific channel
15PNResult<PNGetChannelMetadataResult> getChannelMetadataResponse = await pubnub.GetChannelMetadata()
show all 21 linesResponse
1{
2 "Channel": "my-channel",
3 "Name": "My channel",
4 "Description": "A channel that is mine",
5 "Custom": null,
6 "Updated": "2020-06-17T16:52:19.562469Z"
7}
Set channel metadata
Unsupported partial updates of custom metadata
The value of the custom metadata parameter sent in this method always overwrites the value stored on PubNub servers. If you want to add new custom data to an existing one, you must:
- Get the existing metadata and store it locally.
- Append the new custom metadata to the existing one.
- Set the entire updated custom object.
Set metadata for a Channel in the database, optionally including the custom data object for each.
Method(s)
To Set Channel Metadata you can use the following method(s) in the C# SDK:
1pubnub.SetChannelMetadata()
2 .Channel(string)
3 .Name(string)
4 .Description(string)
5 .Custom(Dictionary<string, object>)
6 .IncludeCustom(bool)
7 .IfMatchesEtag(string)
Channelrequired#- Channel name.
Name#- Channel name.
Description#- Channel description.
Custom#- Custom JSON values. Can be strings, numbers, or booleans. Filtering by
Customisn’t supported. IncludeCustom#- Whether to include the
Customobject in the response. IfMatchesEtag#- Use the eTag from an applicable get metadata call to ensure updates only apply if the object hasn’t changed. If the eTags differ, the server returns HTTP 412.
API limits
To learn about the maximum length of parameters used to set channel metadata, refer to REST API docs.
Sample code
1using PubnubApi;
2
3// Configuration
4PNConfiguration pnConfiguration = new PNConfiguration(new UserId("myUniqueUserId"))
5{
6 SubscribeKey = "demo",
7 PublishKey = "demo",
8 Secure = true
9};
10
11// Initialize PubNub
12Pubnub pubnub = new Pubnub(pnConfiguration);
13
14// Set Metadata for a specific channel
15PNResult<PNSetChannelMetadataResult> setChannelMetadataResponse = await pubnub.SetChannelMetadata()
show all 24 linesResponse
1{
2 "Channel": "my-channel",
3 "Name": "John Doe",
4 "Description": "sample description",
5 "Custom": {
6 "color": "blue"
7 },
8 "Updated": "2020-06-17T16:52:19.562469Z"
9}
Other examples
Iteratively update existing metadata
1using PubnubApi;
2
3PNConfiguration config = new PNConfiguration(new UserId("example"))
4{
5 PublishKey = "demo",
6 SubscribeKey = "demo",
7};
8Pubnub pubnub = new Pubnub(config);
9string channel = "team.red";
10string name = "Red Team";
11string description = "The channel for Red team.";
12var customField = new Dictionary<string, object>()
13{
14 { "visible", "team" },
15};
show all 52 linesRemove channel metadata
Removes the metadata from a specified channel.
Method(s)
To Remove Channel Metadata you can use the following method(s) in the C# SDK:
1pubnub.RemoveChannelMetadata()
2 .Channel(string)
Channelrequired#- Channel name.
Sample code
1using PubnubApi;
2
3// Configuration
4PNConfiguration pnConfiguration = new PNConfiguration(new UserId("myUniqueUserId"))
5{
6 SubscribeKey = "demo",
7 PublishKey = "demo",
8 Secure = true
9};
10
11// Initialize PubNub
12Pubnub pubnub = new Pubnub(pnConfiguration);
13
14// Delete Metadata for a specific channel
15PNResult<PNRemoveChannelMetadataResult> removeChannelMetadataResponse = await pubnub.RemoveChannelMetadata()
show all 20 linesResponse
1{}
Channel memberships
Get channel memberships
This method returns a list of channel memberships for a user. This method doesn't return subscriptions.
Method(s)
To Get Memberships you can use the following method(s) in the C# SDK:
1pubnub.GetMemberships()
2 .Uuid(string)
3 .Include(PNMembershipField[])
4 .IncludeCount(bool)
5 .Page(PNPageObject)
Sample code
1using PubnubApi;
2
3// Configuration
4PNConfiguration pnConfiguration = new PNConfiguration(new UserId("myUniqueUserId"))
5{
6 SubscribeKey = "demo",
7 PublishKey = "demo",
8 Secure = true
9};
10
11// Initialize PubNub
12Pubnub pubnub = new Pubnub(pnConfiguration);
13
14PNResult<PNMembershipsResult> getMembershipsResponse = await pubnub.GetMemberships()
15 .Uuid("my-uuid")
show all 22 linesResponse
1{
2 "Memberships": [
3 {
4 "ChannelMetadata": {
5 "Channel": "my-channel",
6 "Name": "My channel",
7 "Description": "A channel that is mine",
8 "Custom": null,
9 "Updated": "2020-06-17T16:55:44.632042Z"
10 },
11 "Custom": {
12 "starred": false
13 },
14 "Updated": "2020-06-17T17:05:25.987964Z"
15 },
show all 38 linesSet channel memberships
Set channel memberships for a UUID.
Method(s)
To Set Memberships you can use the following method(s) in the C# SDK:
1pubnub.SetMemberships()
2 .Uuid(string)
3 .Channels(List<PNMembership>)
4 .Include(PNMembershipField[])
5 .IncludeCount(bool)
6 .Page(PNPageObject)
7 .Sort(List<string>)
8 .Filter(string)
9 .Limit(int)
Uuidrequired#- Unique user identifier (UUID). If not supplied, the current user's UUID is used.
Channelsrequired#- Channels to add to the membership. Accepts channel names (strings) or objects (with optional custom data).
Include#- Whether to include additional fields.
IncludeCount#- Whether to include the total count in the paginated response. Default is false.
Page#- Cursor-based pagination.
Sort#- Sort by
id,name,updatedwithasc/desc(for example,{name: 'asc'}). Limit#- Number of objects to return. Default/Max: 100.
API limits
To learn about the maximum length of parameters used to set channel membership metadata, refer to REST API docs.
PNMembership
Channelrequired#- The name of the channel associated with this membership.
Custom#- A dictionary that stores custom metadata related to the membership, allowing for additional context or information. Values can be strings, numbers, or booleans.
Status#- The status of the membership, for example: "active" or "inactive"
Type#- The type of membership for categorization purposes.
Sample code
1using PubnubApi;
2
3// Configuration
4PNConfiguration pnConfiguration = new PNConfiguration(new UserId("myUniqueUserId"))
5{
6 SubscribeKey = "demo",
7 PublishKey = "demo",
8 Secure = true
9};
10
11// Initialize PubNub
12Pubnub pubnub = new Pubnub(pnConfiguration);
13
14List<PNMembership> setMembershipChannelMetadataIdList =
15[
show all 28 linesResponse
1{
2 "Memberships": [
3 {
4 "ChannelMetadata": {
5 "Channel": "my-channel",
6 "Name": "My channel",
7 "Description": "A channel that is mine",
8 "Custom": null,
9 "Updated": "2020-06-17T16:55:44.632042Z"
10 },
11 "Custom": {
12 "starred": false
13 },
14 "Updated": "2020-06-17T17:05:25.987964Z"
15 },
show all 38 linesRemove channel memberships
Remove channel memberships for a UUID.
Method(s)
To Remove Memberships you can use the following method(s) in the C# SDK:
1pubnub.RemoveMemberships()
2 .Uuid(string)
3 .Channels(List<string>)
4 .Include(PNMembershipField[])
5 .IncludeCount(bool)
6 .Page(PNPageObject)
7 .Sort(List<string>)
8 .Filter(string)
9 .Limit(int)
Uuid#- Unique user identifier (UUID). If not supplied, the current user's UUID is used.
Channelsrequired#- Channels to remove from membership.
Include#- Whether to include additional fields.
IncludeCount#- Whether to include the total count in the paginated response. Default is false.
Page#- Cursor-based pagination.
Sort#- Sort by
id,name,updatedwithasc/desc(for example,{name: 'asc'}). Limit#- Number of objects to return. Default/Max: 100.
Sample code
1using PubnubApi;
2
3// Configuration
4PNConfiguration pnConfiguration = new PNConfiguration(new UserId("myUniqueUserId"))
5{
6 SubscribeKey = "demo",
7 PublishKey = "demo",
8 Secure = true
9};
10
11// Initialize PubNub
12Pubnub pubnub = new Pubnub(pnConfiguration);
13
14List<string> removeMembershipList =
15[
show all 28 linesResponse
1{
2 "Memberships": [
3 {
4 "ChannelMetadata": {
5 "Channel": "my-channel",
6 "Name": "My channel",
7 "Description": "A channel that is mine",
8 "Custom": null,
9 "Updated": "2020-06-17T16:55:44.632042Z"
10 },
11 "Custom": {
12 "starred": false
13 },
14 "Updated": "2020-06-17T17:05:25.987964Z"
15 },
show all 38 linesManage channel memberships
Set and remove channel memberships for a user.
Method(s)
To Manage Memberships you can use the following method(s) in the C# SDK:
1pubnub.ManageMemberships()
2 .Uuid(string)
3 .Set(List<PNMembership>)
4 .Remove(List<string>)
5 .Include(PNMembershipField[])
6 .IncludeCount(bool)
7 .Page(PNPageObject)
8 .Sort(List<string>)
Uuidrequired#- Unique user identifier (UUID). If not supplied, the current user's UUID is used.
Set#- Set channel memberships for the user.
Remove#- Remove channel memberships for the user.
Include#- Whether to include additional fields.
IncludeCount#- Whether to include the total count in the paginated response. Default is false.
Page#- Cursor-based pagination.
Sort#- Sort by
id,name,updatedwithasc/desc(for example,{name: 'asc'}).
Sample code
1using PubnubApi;
2
3// Configuration
4PNConfiguration pnConfiguration = new PNConfiguration(new UserId("myUniqueUserId"))
5{
6 SubscribeKey = "demo",
7 PublishKey = "demo",
8 Secure = true
9};
10
11// Initialize PubNub
12Pubnub pubnub = new Pubnub(pnConfiguration);
13
14List<PNMembership> setMembrshipList =
15[
show all 37 linesResponse
1{
2 "Memberships": [
3 {
4 "ChannelMetadata": {
5 "Channel": "my-channel",
6 "Name": "My channel",
7 "Description": "A channel that is mine",
8 "Custom": null,
9 "Updated": "2020-06-17T16:55:44.632042Z"
10 },
11 "Custom": {
12 "starred": false
13 },
14 "Updated": "2020-06-17T17:05:25.987964Z"
15 },
show all 38 linesChannel members
Get channel members
This method returns a list of members in a channel. The list includes user metadata for members that have additional metadata stored in the database.
Method(s)
To Get Channel Members you can use the following method(s) in the C# SDK:
1pubnub.GetChannelMembers()
2 .Channel(string)
3 .Include(PNChannelMemberField[])
4 .IncludeCount(bool)
5 .Page(PNPageObject)
6 .Sort(List<string>)
7 .Filter(string)
8 .Limit(int)
Channelrequired#- Channel name.
Include#- Whether to include additional fields.
IncludeCount#- Whether to include the total count in the paginated response. Default is false.
Page#- Cursor-based pagination.
Sort#- Sort by
id,name,updatedwithasc/desc(for example,{name: 'asc'}). Limit#- Number of objects to return. Default/Max: 100.
Sample code
1using PubnubApi;
2
3// Configuration
4PNConfiguration pnConfiguration = new PNConfiguration(new UserId("myUniqueUserId"))
5{
6 SubscribeKey = "demo",
7 PublishKey = "demo",
8 Secure = true
9};
10
11// Initialize PubNub
12Pubnub pubnub = new Pubnub(pnConfiguration);
13
14// Get Members (uuids) for a specific channel
15PNResult<PNChannelMembersResult> getChannelMembersResponse = await pubnub.GetChannelMembers()
show all 22 linesResponse
1{
2 "ChannelMembers": [
3 {
4 "UuidMetadata": {
5 "Uuid": "uuid-1",
6 "Name": "John Doe",
7 "Email": "jack@twitter.com",
8 "ExternalId": "",
9 "ProfileUrl": "",
10 "Custom": null,
11 "Updated": "2019-02-20T23:11:20.89375"
12 },
13 "Custom": {
14 "role": "admin"
15 },
show all 39 linesSet channel members
This method sets members in a channel.
Method(s)
To Set Channel Members you can use the following method(s) in the C# SDK:
1pubnub.SetChannelMembers().Channel(string).Uuids(List<PNChannelMember>).Include(PNChannelMemberField[]).Page(PNPageObject).Sort(List<string>).Filter(string).Limit(int)
Channelrequired#- Channel name.
Uuidsrequired#- Members to add to the channel. Accepts UUIDs (strings) or objects (with optional custom data).
Include#- Whether to include additional fields.
Page#- Cursor-based pagination.
Sort#- Sort by
id,name,updatedwithasc/desc(for example,{name: 'asc'}). Limit#- Number of objects to return. Default/Max: 100.
API limits
To learn about the maximum length of parameters used to set channel members metadata, refer to REST API docs.
Sample code
1using PubnubApi;
2
3// Configuration
4PNConfiguration pnConfiguration = new PNConfiguration(new UserId("myUniqueUserId"))
5{
6 SubscribeKey = "demo",
7 PublishKey = "demo",
8 Secure = true
9};
10
11// Initialize PubNub
12Pubnub pubnub = new Pubnub(pnConfiguration);
13
14// Add Members (UUID) for a specific channel
15List<PNChannelMember> setMemberChannelList =
show all 29 linesResponse
1{
2 "ChannelMembers": [
3 {
4 "UuidMetadata": {
5 "Uuid": "uuid-1",
6 "Name": "John Doe",
7 "Email": "jack@twitter.com",
8 "ExternalId": "",
9 "ProfileUrl": "",
10 "Custom": null,
11 "Updated": "2019-02-20T23:11:20.89375"
12 },
13 "Custom": {
14 "role": "admin"
15 },
show all 39 linesRemove channel members
Remove members from a Channel.
Method(s)
To Remove Channel Members you can use the following method(s) in the C# SDK:
1pubnub.RemoveChannelMembers()
2 .Channel(string)
3 .Remove( List)
4 .Include(PNChannelMembersInclude[])
5 .Limit(int)
6 .Count(bool)
7 .Start(string)
8 .End(string)
9 .Sort(List)
10 .Async()
Channelrequired#- Channel name.
Uuidsrequired#- Members to remove from the channel.
Include#- Whether to include additional fields.
IncludeCount#- Whether to include the total count in the paginated response. Default is false.
Page#- Cursor-based pagination.
Sort#- Sort by
id,name,updatedwithasc/desc(for example,{name: 'asc'}). Limit#- Number of objects to return. Default/Max: 100.
Sample code
1using PubnubApi;
2
3// Configuration
4PNConfiguration pnConfiguration = new PNConfiguration(new UserId("myUniqueUserId"))
5{
6 SubscribeKey = "demo",
7 PublishKey = "demo",
8 Secure = true
9};
10
11// Initialize PubNub
12Pubnub pubnub = new Pubnub(pnConfiguration);
13
14// Remove Members (UUID) for a specific channel
15List<string> removeChannelMemberList =
show all 29 linesResponse
1{
2 "ChannelMembers": [
3 {
4 "UuidMetadata": {
5 "Uuid": "uuid-1",
6 "Name": "John Doe",
7 "Email": "jack@twitter.com",
8 "ExternalId": "",
9 "ProfileUrl": "",
10 "Custom": null,
11 "Updated": "2019-02-20T23:11:20.89375"
12 },
13 "Custom": {
14 "role": "admin"
15 },
show all 39 lines