CAPIBuilder is an open-source web application built with Next.js, TypeScript, and Styled-Component CSS. CAPIBuilder solves an important problem in the data collection process by providing a user-friendly interface for creating and managing survey forms, collecting responses, and reviewing data for Open Data Kit (ODK) API.
CAPIBuilder provides only the web application. To use it, you will need to run the ODK Central server, which is available here: https://github.com/getodk/central
First, copy the example environment file to create your own .env file:
cp .env.example .envThen edit the .env file in the root directory of the project and update the following environment variables:
NEXT_PUBLIC_ODK_CENTRAL_REST_API (The URL of the ODK Central REST API)
NEXT_PUBLIC_ODK_ADMIN_EMAIL (The email of the ODK Central admin user)
NEXT_PUBLIC_ODK_ADMIN_PASSWORD (The password of the ODK Central admin user)
NEXT_PUBLIC_GOOGLE_MEASUREMENT_ID (The Google Measurement ID)
NEXT_PUBLIC_DOCS_URL (The URL of the documentation, optional)
NEXT_PUBLIC_KEYWORDS_REST_API (The URL of the Keywords REST API)
NEXT_PUBLIC_TRANSLATIONS_REST_API (The URL of the Translations REST API)
NEXT_PUBLIC_TEMPLATE_REST_API (The URL of the Template REST API)
NEXT_PUBLIC_API_KEY (The API key for the API)
The deployment can be done by running the command or docker.
git clone https://github.com/capibuilder/capibuilder-odkcd capibuilder-odkYou can install the dependencies using either Yarn or NPM:
-
Yarn:
yarn
-
NPM:
npm install
To start the development server, you can use either Yarn or NPM:
-
Yarn:
yarn dev
-
NPM:
npm run dev
Open http://localhost:3000 in your browser to view the project.
-
Yarn:
yarn build
-
NPM:
npm run build
-
Yarn:
yarn start
-
NPM:
npm run start
Open http://localhost:3000 in your browser to view the production build.