client->newReq('POST', '/api/v1/environment/export'); $request->setHeaderParam('idempotency-key', $options->idempotencyKey); $res = $this->client->send($request); return EnvironmentOut::fromJson($res); } /** * Import a configuration into the active organization. * * It doesn't delete anything, only adds / updates what was passed to it. * * Note that the schema for [`EnvironmentIn`] is subject to change. The fields * herein are provided for convenience but should be treated as JSON blobs. * * @throws ApiException */ public function import( EnvironmentIn $environmentIn, EnvironmentImportOptions $options = new EnvironmentImportOptions(), ): void { $request = $this->client->newReq('POST', '/api/v1/environment/import'); $request->setHeaderParam('idempotency-key', $options->idempotencyKey); $request->setBody(json_encode($environmentIn)); $res = $this->client->sendNoResponseBody($request); } }