introduce a very simple Nextcloud API
This commit is contained in:
@@ -0,0 +1,23 @@
|
||||
using Pilz.Networking.CloudProviders.Nextcloud.OCS.Responses.Cloud;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace Pilz.Networking.CloudProviders.Nextcloud.OCS.APIs
|
||||
{
|
||||
public class OcsApiCloud : OcsApiBase
|
||||
{
|
||||
public readonly static OcsApiUrlPath OCS_CLOUD_USER_METADATA = new("/ocs/v1.php/cloud/users/{0}");
|
||||
|
||||
public OcsApiCloud(OcsApi manager) : base(manager)
|
||||
{
|
||||
}
|
||||
|
||||
public Task<OcsResponseUser?> GetUserMeta(string username)
|
||||
{
|
||||
return Manager.MakeRequestJson<OcsResponseUser>(HttpMethod.Get, OCS_CLOUD_USER_METADATA.FillParameters(username));
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user