Skip to content

Latest commit

 

History

History
39 lines (26 loc) · 1.64 KB

Add Company.md

File metadata and controls

39 lines (26 loc) · 1.64 KB

Add Company

Any formal reporting organization (including corporations, NGOs, Universities, etc.) represented as a company on Wikirate.

This example assumes you have configured your Wikirate REST client. Instructions on how to configure a client can be found in examples/Configurations.md

WikiRate's REST API allows you to create new companies. wikirate4ruby provides the method add_company to allow users to create a new companies. The method takes as an input a number of parameters where all the information about the new company is defined. The parameters can be split into required and optional.

required params:

  • name: company name
  • headquarters: the region/country the headquarters of the company are located. All the available wikirate Regions can be found here.

optional params:

  • open_corporates: company's open corporates identifier
  • wikipedia: company's page name on wikipedia
  • sec_cik: company's central index key as assigned by US Securities and Exchange Commission (SEC)
  • os_id: company's open supply hub identifier

In the example below, we are creating a wikirate company for Nike Inc.

nike = client.add_company({ 'name'=> 'Nike Inc.', 
                            'headquarters'=>'United States',
                            'open_corporates'=>'8739914',
                            'sec_cik'=>'0000320187',
                            'os_id'=>'US2020349PNHW2P'})