Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
新注册的用户请输入邮箱并保存,随后登录邮箱激活账号。后续可直接使用邮箱登录!
Open sidebar
chainweaver
did
did-admin
Commits
ef582f64
Commit
ef582f64
authored
1 year ago
by
Guoxin.Liu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix: document service --story=0
parent
97dd8b6c
master
develop
v1.1.0
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
24 additions
and
15 deletions
+24
-15
internal/types/types.go
internal/types/types.go
+9
-6
template/cnbn-did.api
template/cnbn-did.api
+15
-9
No files found.
internal/types/types.go
View file @
ef582f64
...
...
@@ -93,8 +93,9 @@ type DocumentRegisterRequest struct {
}
type
DocumentUpdateRequest
struct
{
Did
string
`json:"did,omitempty"`
Proof
[]
Proof
`json:"proof,omitempty"`
Did
string
`json:"did,omitempty,optional"`
Proof
[]
Proof
`json:"proof,omitempty,optional"`
Document
Document
`json:"document,omitempty,optional"`
}
type
DocumentGetRequest
struct
{
...
...
@@ -237,8 +238,10 @@ type GenUpdateDocumentVerificationMethodRequest struct {
}
type
GenDocumentRegisterRequest
struct
{
Did
string
`json:"did,optional"`
PublicKey
[]
string
`json:"publicKey,optional"`
Did
string
`json:"did,optional"`
PublicKey
[]
string
`json:"publicKey,optional"`
UnionId
map
[
string
]
string
`json:"unionId,optional"`
Service
Service
`json:"service,optional"`
}
type
GenDocumentRegisterResponse
struct
{
...
...
@@ -320,7 +323,7 @@ type FindDIDByCompanyNameRequest struct {
type
FindDIDByCompanyNameResponse
struct
{
Code
int32
`json:"code"`
Msg
string
`json:"msg"`
Data
FindDIDByCompanyNameData
`json:"data"`
Data
FindDIDByCompanyNameData
`json:"data
,omitempty
"`
}
type
FindDIDByCompanyNameData
struct
{
...
...
@@ -334,7 +337,7 @@ type FindCompanyNameByDIDRequest struct {
type
FindCompanyNameByDIDResponse
struct
{
Code
int32
`json:"code"`
Msg
string
`json:"msg"`
Data
FindCompanyNameByDIDResponseData
`json:"data"`
Data
FindCompanyNameByDIDResponseData
`json:"data
,omitempty
"`
}
type
FindCompanyNameByDIDResponseData
struct
{
...
...
This diff is collapsed.
Click to expand it.
template/cnbn-did.api
View file @
ef582f64
...
...
@@ -88,8 +88,9 @@ type (
}
DocumentUpdateRequest {
Did string `json:"did,omitempty"`
Proof []Proof `json:"proof,omitempty"`
Did string `json:"did,omitempty,optional"`
Proof []Proof `json:"proof,omitempty,optional"`
Document Document `json:"document,omitempty,optional"`
}
DocumentGetRequest {
Did string `json:"did,omitempty"`
...
...
@@ -277,8 +278,10 @@ type (
}
// 生成DID注册文档 请求
GenDocumentRegisterRequest {
Did string `json:"did,optional"`
PublicKey []string `json:"publicKey,optional"`
Did string `json:"did,optional"`
PublicKey []string `json:"publicKey,optional"`
UnionId map[string]string `json:"unionId,optional"`
Service Service `json:"service,optional"`
}
GenDocumentRegisterResponse {
Code int32 `json:"code"`
...
...
@@ -339,9 +342,8 @@ type (
TemplateId string `json:"templateId"`
Holder string `json:"holder"`
ExpirationDate string `json:"expirationDate"`
Issuer string `json:"issuer"`
IssuanceDate string `json:"issuanceDate"`
CredentialSubject XXXXXRawMessage `json:"credentialSubject"`
CredentialSubject XXXXXRawMessage `json:"credentialSubject
,omitempty,optional
"`
Proof []LongProof `json:"proof,omitempty,optional"`
}
VcIssueResponse {
...
...
@@ -367,15 +369,15 @@ type (
Msg string `json:"msg"`
Data FindDIDByCompanyNameData `json:"data,omitempty"`
}
FindDIDByCompanyNameData{
FindDIDByCompanyNameData
{
Did string `json:"did"`
}
FindCompanyNameByDIDRequest {
Did string `json:"did"`
}
FindCompanyNameByDIDResponse {
Code int32 `json:"code"`
Msg string `json:"msg"`
Code int32
`json:"code"`
Msg string
`json:"msg"`
Data FindCompanyNameByDIDResponseData `json:"data,omitempty"`
}
FindCompanyNameByDIDResponseData {
...
...
@@ -407,6 +409,10 @@ service cnbn-did {
@handler findDIDByCompanyName
post /find-did-by-company-name (FindDIDByCompanyNameRequest) returns (FindDIDByCompanyNameResponse)
@handler findCompanyNameByDID
post /find-company-name-by-did (FindCompanyNameByDIDRequest) returns (FindCompanyNameByDIDResponse)
}
type (
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment