/* istanbul ignore file */ /* tslint:disable */ /* eslint-disable */ import type { CancelablePromise } from '../core/CancelablePromise'; import { request as __request } from '../core/request'; export class IpfsService { /** * Get file from IPFS *
Gets data from the IPFS.
* @param id IPFS CID of the file * @returns binary OK * @throws ApiError */ public static getIpfsData( id: string, ): CancelablePromiseStores file on the IPFS. We are leveraging nft.storage from Protocol Labs for free storage on the IPFS.
* * @param formData * @returns any OK * @throws ApiError */ public static storeIpfs( formData: { /** * Your file to store */ file?: Blob; }, ): CancelablePromise<{ /** * IPFS CID identifier of the stored file. */ ipfsHash?: string; }> { return __request({ method: 'POST', path: `/v3/ipfs`, formData: formData, mediaType: 'multipart/form-data', errors: { 400: `Bad Request. Validation failed for the given object in the HTTP Body or Request parameters.`, 401: `Unauthorized. Not valid or inactive subscription key present in the HTTP Header.`, 403: `Forbidden. The request is authenticated, but it is not possible to perform the required operation due to a logical error or invalid permissions.`, 500: `Internal server error. There was an error on the server while processing the request.`, }, }); } }