UNPKG

wikibase-cli

Version:

A command-line interface to Wikibase

23 lines (21 loc) 966 B
import { editCommandsOptions } from '#lib/common_options' export default { alias: 'ce', args: '<data>', description: 'Create a new entity', options: editCommandsOptions, examples: [ { args: "'{\"labels\":{\"en\":\"a label\",\"fr\":\"un label\"},\"descriptions\":{\"en\":\"some description\",\"fr\":\"une description\"},\"claims\":{\"P1775\":[\"Q3576110\",\"Q12206942\"],\"P2002\":\"bulgroz\"}}'", comment: 'Pass data as JSON', }, { args: './new_entity_data.json', comment: 'Pass data as a JSON file path', }, { args: './new_entity_data.json --instance http://some/wikibase/instance/w/api.php --sparql-endpoint http://some/sparql/endpoint', comment: 'In case you use are not editing wikidata.org, make sure to specify the custom Wikibase instance and its SPARQL endpoint, as claims formatting and validation will depend on properties types that are retrieved from the SPARQL endpoint', }, ], }