Git Product home page Git Product logo

kutt's Introduction

Kutt cli

CLI

Signup in kutt.it and in setting menu generate an API Key and run kutt config help

> pip install kutt

Type kutt [COMMAND] --help for get help

lib

use kutt in your code in this sul:

from kutt import kutt

API = "YOUR_API_KEY"

# For submit a new URL
# obj variable has url object data (read the https://github.com/thedevs-network/kutt#api document)
obj = kutt.submit(
    API,
    "URL",
    description="OPTIONAL description",
    expire_in="OPTIONAL expire time",
    password="OPTIONAL password",
    customurl="OPTIONAL customurl",
    description="OPTIONAL desciption",
    domain="OPTIONAL custom domain",
    reuse=True, # OPTIONAL
    )

# For delete a URL
kutt.delete(API, "ID")


# update a URL 
kutt.update(API, "ID", "URL", "address", description="OPTIONAL description", expire_in="OPTIONAL expire time")


# Get urls list
links = kutt.links(API, limit=10, skip=0)

# Get url stats
stats = kutt.stats(API, "ID")

kutt's People

Contributors

amirali avatar amirarj avatar antsar avatar felixwttr avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

kutt's Issues

CLI error

I'm getting this error in cli when type kutt:

Traceback (most recent call last):
  File "/usr/local/bin/kutt", line 6, in <module>
    from kutt.cli import cli
ImportError: No module named kutt.cli

Reuse must be boolean.

got this error when using reuse option

{'code': 400, 'data': {'error': 'Reuse must be boolean.'}}

code:
obj = kutt.submit(API, 'https://github.com/', reuse=True)
print(obj)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.