dptsi / blob-repository
Upload Blob to repository ITS.
Installs: 67
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 6
Forks: 0
Open Issues: 0
pkg:composer/dptsi/blob-repository
Requires
- guzzlehttp/guzzle: ~6.0|^6.5|^7.0.1
This package is auto-updated.
Last update: 2025-10-26 03:19:33 UTC
README
Repository ini berisi library PHP yang digunakan untuk mengunggah file ke storage API ITS
Requirements
- PHP 5.4 ++
- guzzle
example is in test-upload.php
Instalation
add composer.json
"dptsi/blob-repository": "dev-master"
after require section add this
"repositories": [
{
"type": "vcs",
"url": "https://github.com/dptsi/blob-repository.git"
}
]
Usage
Instalation
<?php
require './vendor/autoload.php';
$blobUpload = new BlobRepository('SSO Provider', 'SSO Client ID', 'SSO Secret', 'Alamat Storage API (Kosong jika prod)');
Get File
$file = $blobUpload->getFile($file_id);
Store File
$file Upload = $blobUpload->storeFile($_FILES['fileToUpload']);
Delete File
$file Upload = $blobUpload->deleteFile($file_id);
Update File
$file Upload = $blobUpload->updateFile($_FILES['fileToUpload'], $file_id);
Methods
file_id()
file_name()
tag()
timestamp()
public_link()
To get responses from server access $file->response