警告
内容已严重过时
浅浅整理一下已知的中育 API
以下请求内容均以 C# 形式书写,实际请求时需要序列化为 JSON,有些还需要加密
信息
云笔记的大部分 API 都对请求内容和返回值中的 data 做了 AES 加密,但是 AES 的密钥可以在某个地方找到,详见此处
警告
AES 密钥已更改。
POSThttp://note.func.zykj.org/api/Account/GuestLogin
Content-Type: application/json
//请求时序列化并加密
public class LoginData
{
public string clientCode { get; set; }
public string password { get; set; }
public string schoolCode { get; set; }
public string smsVerificationCode { get; set; };
public string userName { get; set; }
}
public class CommonResponseData
{
public int code { get; set; }
public string msg { get; set; }
public string data { get; set; }
// data项解密并反序列化后得到 UserInfo
}
public class UserInfo
{
public string token { get; set; }
public int userId { get; set; }
public string realName { get; set; }
public int roleType { get; set; }
public string ezyServer { get; set; }
public object mobile { get; set; }
public object clientCode { get; set; }
public string accessKeyId { get; set; }
public string accessKeySecret { get; set; }
public string securityToken { get; set; }
}
GEThttp://note.func.zykj.org/api/Notes/GetAll
Authorization: bearer {UserInfo.Token}
空
public class CommonResponseData
{
public int code { get; set; }
public string msg { get; set; }
public string data { get; set; }
// data项解密并反序列化后得到 GetAllNotesResponseData
}
public class GetAllNotesResponseData
{
public int userId { get; set; }
public string schoolCode { get; set; }
public int totalCount { get; set; }
public NoteInfo[] noteList { get; set; }
}
public class NoteInfo
{
public string fileId { get; set; }
public string fileName { get; set; }
public string fileUrl { get; set; }
public string parentId { get; set; }
public int type { get; set; }
public string createTime { get; set; }
public string updateTime { get; set; }
public int version { get; set; }
public bool shared { get; set; }
}
GEThttp://note.func.zykj.org/api/Account/GetOssToken
Authorization: bearer {UserInfo.Token}
空
public class CommonResponseData
{
public int code { get; set; }
public string msg { get; set; }
public string data { get; set; }
// data项解密并反序列化后得到 OssAccessResponseData
}
public class OssAccessResponseData
{
public string accessKeyId { get; set; }
public string accessKeySecret { get; set; }
public string securityToken { get; set; }
public string requestId { get; set; }
}
POSThttp://note.func.zykj.org/api/Notes/AddOrUpdate
Authorization: bearer {UserInfo.Token}
Content-Type: application/json
//请求时序列化并加密
public class AddFileData
{
public string fileId { get; set; }
public string fileName { get; set; }
public string fileUrl { get; set; }
public string parentId { get; set; }
public int type { get; set; }
}
public class MinimumResponseData
{
public int code { get; set; }
public string msg { get; set; }
}
POSThttp://note.func.zykj.org/api/Notes/Delete
Authorization: bearer {UserInfo.Token}
Content-Type: application/json
["{NoteInfo.fileId}"]
public class MinimumResponseData
{
public int code { get; set; }
public string msg { get; set; }
}
这些 API 暂时没有加密 {:.note}