taler-docs

Documentation for GNU Taler components, APIs and protocols
Log | Files | Refs | README | LICENSE

post-csr-issue.rst (1855B)


      1 .. http:post:: /csr-issue
      2 
      3   Obtain donau-side input values in preparation for a
      4   issue receipt step for certain donation unit cipher types,
      5   specifically at this point for Clause-Schnorr blind
      6   signatures. This API is used by the donor.
      7 
      8   **Request:** The request body must be a `IssuePrepareRequest` object.
      9 
     10   **Response:**
     11 
     12   :http:statuscode:`200 OK`:
     13     The request was successful, and the response is a `IssuePrepareResponse`.  Note that repeating exactly the same request
     14     will again yield the same response (assuming none of the donation unit is expired).
     15   :http:statuscode:`404 Not found`:
     16     The donation unit key is not known to the donau.
     17   :http:statuscode:`410 Gone`:
     18     The requested donation unit key is not yet or no longer valid. It either before the validity year, past the
     19     year or was revoked. The response is a `DonationUnitExpiredMessage`. Clients must evaluate the error code provided to
     20     understand which of the cases this is and handle it accordingly.
     21 
     22   **Details:**
     23 
     24   .. ts:def:: IssuePrepareRequest
     25 
     26     interface IssuePrepareRequest {
     27 
     28       // Nonce to be used by the donau to derive
     29       // its private inputs from. Must not have ever
     30       // been used before.
     31       nonce: CSNonce;
     32 
     33       // Hash of the public key of the donation unit
     34       // the request relates to.
     35       du_pub_hash: HashCode;
     36 
     37     }
     38 
     39   .. ts:def:: IssuePrepareResponse
     40 
     41     type IssuePrepareResponse =
     42       | DonauIssueValue;
     43 
     44   .. ts:def:: DonauIssueValue
     45 
     46     type DonauIssueValue =
     47       | DonauRsaIssueValue
     48       | DonauCsIssueValue;
     49 
     50   .. ts:def:: DonauRsaIssueValue
     51 
     52     interface DonauRsaIssueValue {
     53       cipher: "RSA";
     54     }
     55 
     56   .. ts:def:: DonauCsIssueValue
     57 
     58     interface DonauCsIssueValue {
     59       cipher: "CS";
     60 
     61       // CSR R0 value
     62       r_pub_0: CSRPublic;
     63 
     64       // CSR R1 value
     65       r_pub_1: CSRPublic;
     66     }