Skip to content

Latest commit

 

History

History
28 lines (20 loc) · 1.21 KB

File metadata and controls

28 lines (20 loc) · 1.21 KB

Google Developer Knowledge API Java Samples

This directory contains Java code samples demonstrating how to use the Google Developer Knowledge API client library (com.google.cloud:google-cloud-developer-knowledge).

Setup

  1. Enable the Developer Knowledge API on your Google Cloud project:

    gcloud services enable developerknowledge.googleapis.com
  2. Build with Maven:

    mvn clean compile

Samples

  • Search Document Chunks: Search public developer documentation chunks by query (developerknowledge_search_document_chunks).
  • Get Document: Retrieve a single documentation page with full markdown content (developerknowledge_get_document).
  • Batch Get Documents: Fetch multiple documentation pages in one call (developerknowledge_batch_get_documents).
  • Answer Query: Get a grounded, cited answer to a technical question (developerknowledge_answer_query).

Running Tests

mvn test