Actions
RegisterProposal¶
- 제안서를 등록합니다.
registerProposal(
param: ProposalRegisterRequest
): ProposalResponse
ProposalRegisterRequest (param)
| field | type | description | note |
| did | String | ||
| command | String | 값 : registerProposal | |
| status | int | ||
| purpose | int | ||
| maxIssuable | int | ||
| category | int[] | ||
| disAllowMultiIssue | boolean | ||
| condition | String | 필수 | |
| content | String | Escape 처리 필요 | |
| createdAt | String | ||
| revokedAt | String | ||
| updatedAt | String | ||
| deposit | String | ||
| duration | String | ||
| filter | String | ||
| notAfter | String | ||
| notBefore | String | ||
| owner | String | ||
| proposalId | String | ||
| ticketValidFrom | String | ||
| description | String[] | ||
| imageurl | String[] | ||
| consumePolicy | ProposalConsumePolicy | ||
| rewardPolicy | ProposalRewardPolicy |
ProposalConsumePolicy
| field | type | description | note |
| type | int | 소모 유형 | |
| count | int | 소모 허용 횟수 | |
| maxDataCount | int | consume시 최대 데이터 소모 수 | optional |
| period | String | 소모 주기 | optional |
ProposalRewardPolicy
| field | type | description |
| type | int | 지급 유형 |
| amount | int | 티켓의 지급 가능 총량 |
| tokenDuration | String | 리워드 유효기간 |
ProposalResponse
| field | type | description | note |
| command | String | 값 : registerProposal | |
| status | int | ||
| purpose | int | ||
| maxIssuable | int | ||
| category | int[] | ||
| disAllowMultiIssue | boolean | ||
| condition | String | ||
| content | String | ||
| createdAt | String | ||
| revokedAt | String | ||
| updatedAt | String | ||
| deposit | String | ||
| duration | String | ||
| filter | String | ||
| notAfter | String | ||
| notBefore | String | ||
| owner | String | ||
| proposalId | String | ||
| ticketValidFrom | String | ||
| description | String[] | ||
| imageurl | String[] | ||
| consumePolicy | ProposalConsumePolicy | ||
| rewardPolicy | ProposalRewardPolicy |
Request Example
mutation {
registerProposal (param: {
did: "NfoPEFaG1adkCpijR85L66"
command: "registerProposal"
status: 0
purpose:0
maxIssuable:10
imageurl: [
"Icon=https://cdn.myd.world/images/snplab.png",
"Banner=https://cdn.myd.world/images/commonwallpaper.png",
"Landing=https://cdn.myd.world/images/commonwallpaper.png"
]
consumePolicy: {
type:2
count:1
maxDataCount:1
}
category: [
3,
10,
8
]
description: [
"CompanyName=NH농협은행",
"Title=NH농협은행 컨소시엄",
"Disclaimer=한글지원 테스트입니다",
"PrivacyPolicy=개인정보 처리방침"
]
rewardPolicy: {
amount: 10
type:1
}
ticketValidFrom: ""
condition: "*"
owner: ""
createdAt: ""
duration: "3w"
notAfter: "2021-06-30T03:22:17.448Z"
updatedAt: ""
revokedAt: ""
notBefore: "2021-05-15T03:22:17.448Z"
filter: "*"
disAllowMultiIssue: false
content: "{\r\n\"Advertisement\":{\r\n\"Title\":\"\uAC04\uD3B8\uACB0\uC81C\uC774\uC6A9\uACE0\uAC1D\uB2D8\uC744\uC704\uD55C\uC785\uCD9C\uC2DD\uD2B9\uD654\uC0C1\uD488\",\r\n\"Banner\":\"https:\/\/test.snplab.io\/ad_sample\/test004.png\",\r\n\"Landing\":\"https:\/\/test.snplab.io\/ad_sample\/test004.html\",\r\n\"Disclaimer\":\"https:\/\/test.snplab.io\/ad_sample\/Disclaimer_004.txt\",\r\n\"MoreInfo\":\"https:\/\/www.nhcapital.co.kr\/home\/homemain.nh\"\r\n},\r\n\"Target\":\"\\\"Name\\\":\\\"order-month\\\",\\\"Property\\\":\\\"Order.orderDate\\\",\\\"BinType\\\":\\\"RANGE\\\",\\\"Bins\\\":[[\\\"2020-01-01T00:00:00+09:00\\\",\\\"2020-04-01T00:00:00+09:00\\\"],[\\\"2020-04-01T00:00:00+09:00\\\",\\\"2020-07-01T00:00:00+09:00\\\"],[\\\"2020-07-01T00:00:00+09:00\\\",\\\"2020-10-01T00:00:00+09:00\\\"],[\\\"2020-09-01T00:00:00+09:00\\\",\\\"2020-12-01T00:00:00+09:00\\\"]]\",\r\n\"LdpConfig\":{\r\n\"PrivacyBudget\":4,\r\n\"Formula\":1\r\n}\r\n}"
}) {
command
owner
status
filter
purpose
maxIssuable
proposalId
}
}
Response Example
{
"data": {
"registerProposal": {
"command": "registerProposal",
"owner": "NfoPEFaG1adkCpijR85L66",
"status": 1,
"filter": "*",
"purpose": 0,
"maxIssuable": 10,
"proposalId": "orPxmv15e2oSPufT3Tm5kBTWEuErMeLvdYrXdEnzsHtQMWbVwiq6TGBgczmdbh9UrSXB9YRKTG15w5EzM8Na5XRFaPxaW8LzmckzP8bSLq67pRM7X"
}
}
}
필드 관련하여 자세한 내용은 아래 URL 참고
이름없음이(가) 약 2년 전에 변경 · 1 revisions