Numerology API - Java

Numerology API with Java ☕

Integrate Numerology API into your Java application.

Installation

No package to install. This example uses the java.net.http client built into Java 17 and later.

Example Code

import java.net.URI;
import java.net.http.HttpClient;
import java.net.http.HttpRequest;
import java.net.http.HttpResponse;

public class VedikaExample {
    public static void main(String[] args) throws Exception {
        String body = """
            {
              "name": "Asha Rao",
              "birthDate": "1990-06-15"
            }
            """;
        HttpRequest request = HttpRequest.newBuilder()
            .uri(URI.create("https://api.vedika.io/v2/astrology/numerology/complete"))
            .header("Authorization", "Bearer YOUR_API_KEY")
            .header("Content-Type", "application/json")
            .POST(HttpRequest.BodyPublishers.ofString(body))
            .build();
        HttpResponse<String> response = HttpClient.newHttpClient()
            .send(request, HttpResponse.BodyHandlers.ofString());
        System.out.println(response.statusCode());
        System.out.println(response.body());
    }
}

Get Started Free

Try our sandbox API with no authentication required

Try Sandbox Read Docs