Assignment Validator Decoded Datum
Node Backend APINBA Assignment Validator
Retrieves decoded datum for an assignment validator based on the provided policy and optional alias. This endpoint provides detailed information about committed assignments, including student details, course state, and validator addresses.
X-API-Key<token>
API Key for authentication. Example: "YOUR_API_KEY"
In: header
Assignment Validator Decoded Datum Request Body - Contains the policy ID of the assignment validator and an optional alias.
alias?string
policy?string
Response Body
curl -X POST "https://andamio-api-308006323670.us-central1.run.app/api/v1/node-backend-api/assignment-validator/decoded-datum" \
-H "Content-Type: application/json" \
-d '{}'
const body = JSON.stringify({})
fetch("https://andamio-api-308006323670.us-central1.run.app/api/v1/node-backend-api/assignment-validator/decoded-datum", {
body
})
package main
import (
"fmt"
"net/http"
"io/ioutil"
"strings"
)
func main() {
url := "https://andamio-api-308006323670.us-central1.run.app/api/v1/node-backend-api/assignment-validator/decoded-datum"
body := strings.NewReader(`{}`)
req, _ := http.NewRequest("POST", url, body)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}
import requests
url = "https://andamio-api-308006323670.us-central1.run.app/api/v1/node-backend-api/assignment-validator/decoded-datum"
body = {}
response = requests.request("POST", url, json = body, headers = {
"Content-Type": "application/json"
})
print(response.text)
import java.net.URI;
import java.net.http.HttpClient;
import java.net.http.HttpRequest;
import java.net.http.HttpResponse;
import java.net.http.HttpResponse.BodyHandlers;
import java.time.Duration;
import java.net.http.HttpRequest.BodyPublishers;
var body = BodyPublishers.ofString("""{}""");
HttpClient client = HttpClient.newBuilder()
.connectTimeout(Duration.ofSeconds(10))
.build();
HttpRequest.Builder requestBuilder = HttpRequest.newBuilder()
.uri(URI.create("https://andamio-api-308006323670.us-central1.run.app/api/v1/node-backend-api/assignment-validator/decoded-datum"))
.header("Content-Type", "application/json")
.POST(body)
.build();
try {
HttpResponse<String> response = client.send(requestBuilder.build(), BodyHandlers.ofString());
System.out.println("Status code: " + response.statusCode());
System.out.println("Response body: " + response.body());
} catch (Exception e) {
e.printStackTrace();
}
using System;
using System.Net.Http;
using System.Text;
var body = new StringContent("""
{}
""", Encoding.UTF8, "application/json");
var client = new HttpClient();
var response = await client.PostAsync("https://andamio-api-308006323670.us-central1.run.app/api/v1/node-backend-api/assignment-validator/decoded-datum", body);
var responseBody = await response.Content.ReadAsStringAsync();
[
{
"committedAssignmentId": "hex_string_assignment_id",
"courseState": {
"completedAssignments": [
"[\"assignment_hash_1\"",
" \"assignment_hash_2\"]"
],
"courseCs": "hex_string_course_cs",
"csdUserName": "course_student_name",
"globalCs": "hex_string_global_cs"
},
"courseStateCs": "hex_string_course_state_cs",
"courseUserName": "student_name",
"courseValAddr": "course_validator_address",
"studentAssignmentInfo": [
"[\"info1\"",
" \"info2\"]"
]
}
]
{
"details": "string",
"message": "Bad Request: Invalid input.",
"statusCode": 400
}
{
"details": "string",
"message": "Unauthorized: Invalid or missing credentials.",
"statusCode": 401
}
{
"details": "string",
"message": "Forbidden: Insufficient permissions or tier access.",
"statusCode": 403
}
{
"details": "string",
"message": "Unprocessable Entity: Invalid request structure or data.",
"statusCode": 422
}
{
"details": "string",
"message": "Too Many Requests: Rate limit or quota exceeded.",
"statusCode": 429
}
{
"details": "string",
"message": "Internal Server Error: An unexpected error occurred.",
"statusCode": 500
}