Skip to main content

Package to upload object to aws s3 and return s3 file url

Project description

File upload to AWS S3

This packge can be used to upload file in s3 and get file generated url.

Steps to use package

  1. Install package with pip install fileUploadS3_x21182787
  2. import package in python and use it
>> from fileUploadS3_x21182787 import uploadGenrateUrl

>> uploadGenrateUrl.s3UploadGenURL("b64EncodedData","filename.ext","bucket_name")

Funcation Description

s3UploadGenURL(b64EncodedData, s3_file, bucket_name) will take 3 parameters

  1. b64EncodedData - Data should be in base64 encoded formate.
  2. s3_file - File name in which data to be stored eg. abc.jpg, file.doc etc...
  3. bucket_name - S3 bucket name file to be store.

Example

import json
from fileUploadS3_x21182787 import uploadGenerateUrl

response = uploadGenrateUrl.s3UploadGenURL("b64EncodedData","filename.ext","bucket_name")

print(json.loads(response)) # {"img_url": "s3_file_url"}

print(json.loads(response)[img_url]) # will print s3_file_url
Note:
Before using the response convert it to json `json.loads(response)`. because package returing stringified json.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

fileuploads3_x21182787-0.0.1.tar.gz (2.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

fileuploads3_x21182787-0.0.1-py3-none-any.whl (3.2 kB view details)

Uploaded Python 3

File details

Details for the file fileuploads3_x21182787-0.0.1.tar.gz.

File metadata

  • Download URL: fileuploads3_x21182787-0.0.1.tar.gz
  • Upload date:
  • Size: 2.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.10.0

File hashes

Hashes for fileuploads3_x21182787-0.0.1.tar.gz
Algorithm Hash digest
SHA256 e508ed2a34564802b051ef5dd652fbba142d0761faad9a7cd8f3973c7482cb13
MD5 19eb954decf69ba0e16d7c57ebd3203d
BLAKE2b-256 e0220af3d38a068ff73e6a49938559e92db0efca568acf9836e6317ff1ca2a24

See more details on using hashes here.

File details

Details for the file fileuploads3_x21182787-0.0.1-py3-none-any.whl.

File metadata

File hashes

Hashes for fileuploads3_x21182787-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 30f87cdd0ee2c2ba4615ebe3013967852d75569350c3337c69080066a105785a
MD5 16664c1f3408a24872b43c46f68d4da5
BLAKE2b-256 13dbf4970191af0759e3827acab4fc8b1735290c4fa5335db000adb46331bb9e

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page