'{username}', 'apiKey' => '{apiKey}', )); // 2. Obtain an Object Store service object from the client. $objectStoreService = $client->objectStoreService(null, '{region}'); // 3. Get container. $container = $objectStoreService->getContainer('{containerName}'); // 4. Open local file $fileData = fopen('{localFilePath}', 'r'); // 5. Upload it! Note that while we call fopen to open the file resource, we do // not call fclose at the end. The file resource is automatically closed inside // the uploadObject call. $container->uploadObject('{remoteObjectName}', $fileData);