The main API (the so-called REST API) allows access as data to all aspects of the OpenCorporates website (with the exception of being able submit data). By default it returns data as JSON (but XML is also available). Access to all the data is free and under the same open licence conditions as the rest of OpenCorporates. An optional (free) API token is available which increases usage limits for the service.
If you are matching company names to legal entities from an existing dataset, you should investigate the rather excellent Google Refine, which makes this quick, easy and allows data to be filtered and cleansed quicker than any other tool we know of. OpenCorporates provides a highly popular reconciliation API for Google Refine, which allows matching company names to legal entities.