DEV Community

Cover image for PinFu: A Dual-Purpose Application for Effortless File Uploads to Pinata
Abu Taher Siddik
Abu Taher Siddik

Posted on • Edited on

PinFu: A Dual-Purpose Application for Effortless File Uploads to Pinata

What I Built

PinFu is a dual-purpose application designed for seamless file uploads to Pinata. It consists of two components:

  1. PinFu Web Application: A user-friendly web interface built with PHP that allows users to manage their Pinata API keys, upload files, and view uploaded files on IPFS.

  2. PinFu CLI Application: A command-line interface that enables users to upload files directly from the terminal, manage API keys, and view uploaded files easily.

Demo

You can access the web application at PinFu Demo. Below are some screenshots showcasing the user interface:

PinFu Web Upload
Image description

Image description
Uploaded Files

Image description

My Code

You can find the source code for both the web application and CLI in this GitHub repository: PinFu Repository.

GitHub logo imabutahersiddik / pinfu

Web app for uploading files to Pinata with a user-friendly interface and API key management.

PinFu - Pinata File Upload

PinFu is a web-based application that allows users to upload files to the Pinata platform seamlessly. Built using PHP, PinFu provides a user-friendly interface for managing API keys, uploading files, and viewing uploaded files on IPFS.

Table of Contents

Features

  • Save and manage your Pinata API keys securely through the UI.
  • Upload various types of files (images, videos, documents) to Pinata.
  • View the IPFS hash and link for each uploaded file.
  • User-friendly interface for easy navigation.

Requirements

  • PHP 7.4 or higher
  • A web server (e.g., Apache, Nginx)
  • Access to the internet for API requests

Installation

  1. Clone the repository:

    git clone https://github.com/imabutahersiddik/pinfu.git
    cd pinfu
    php -S localhost:8000
    Enter fullscreen mode Exit fullscreen mode
  2. Ensure Composer dependencies are installed:

    • Composer is already installed in the repository, so no additional installation is necessary.
  3. Configure your web server:

    • Set…
  • Web Application: /pinfu
  • CLI Application: /pinfu/pinata_cli

More Details

How I Used Pinata

  • API Integration: Both applications utilize Pinata's Files API to handle file uploads efficiently. Users can save their API keys directly through the UI or CLI.

  • File Uploads: The web app allows users to select files from their local machine and upload them to Pinata, displaying the IPFS hash upon successful upload. The CLI app offers a similar experience but through terminal commands.

  • Viewing Uploaded Files: Users can view a list of uploaded files along with their IPFS hashes and direct links to access them via Pinata's gateway.

What's New in the October 13, 2024 Update

1. Enhanced File Upload Details

  • SHA-256 Hash Storage: Each uploaded file now includes a SHA-256 hash for improved verification and integrity checks.
  • Upload Date Tracking: The date and time of each file upload are now recorded, allowing users to see when files were added.

2. Social Media Sharing Functionality

  • Share Buttons Added: Users can now easily share uploaded files on popular social media platforms, including:
    • Facebook
    • Twitter
    • LinkedIn
    • WhatsApp
  • Iconify Integration: Social share buttons feature icons from the Iconify library for a modern and visually appealing interface.

3. Added Tabs for Categorization

  • File Category Tabs: The application now includes dedicated tabs for categorizing uploaded files, such as Images, Videos, Archives, and Software. This allows users to easily navigate and manage their files based on type.

4. Improved Pagination Logic

  • Category-Specific Pagination: Pagination functionality has been enhanced to work seamlessly with different file categories, allowing users to navigate through their uploaded files easily.
  • Current Category Detection: The application now intelligently detects the current tab/category, ensuring that pagination works correctly for each section.

What's New in the October 14, 2024 Update

1. Enhanced File Upload with Drag-and-Drop Support

The addition of drag-and-drop functionality greatly improves the file upload process.

2. File Size Displayed in User Interface

Easily view file sizes in the UI for quick access and better file management.

Summary

This update enhances the overall functionality and user experience of the application by adding important features such as file integrity tracking, social sharing options, and improved categorization through dedicated tabs. Users can now manage their uploaded files more effectively while sharing them effortlessly across social media platforms.

Top comments (0)