urbanpython是城市字典JSON API的API包装器

urbanpython的Python项目详细描述


乌班Python

urbanpython是城市字典JSON API的API包装器

安装

要安装urbanpy,请执行以下操作:

pip install urbanpython

或者

python -m pip install urbanpython

文件

此自述文件是文档

示例

要获取API密钥,请转到https://rapidapi.com/community/api/urban-dictionary/endpoints并获取API密钥

This is your API key

importurbanpythonurban=urbanpython.Urban("-your api key-")result=urban.search("the thing you are gonna search")print(result.definition)#Definition of the postprint(result.permalink)#The link to the postprint(result.thumbs_up)#Number of thumbs upsprint(result.thumbs_down)#Number of thumbs downsprint(result.sounds_url)#A list of the sounds urls in the postprint(result.author)#The author of the postprint(result.defid)#The ID of the definitionprint(result.written_on)#The time the definition got written onprint(result.example)#The example of the post

欢迎加入QQ群-->: 979659372 Python中文网_新手群

推荐PyPI第三方库


热门话题
java为什么会出现这些错误?表达式的非法开始   使用HttpUrlConnection的java测试URL仅适用于前面的www   在大数据集上使用kmeans的java堆外内存   查找Java RandomAccessFile如何以字符形式读取第n个字节   java Android从BroadcastReceiver获取标题和描述   java使用构造函数参数模拟嵌套类并测试方法   正在将Azure Blob项强制转换为Java文件对象   java并行运行testNG套件   java程序在运行时似乎没有进入   贬低Java规则引擎的优点和缺点   文本区域中的java中心文本   java JPA从多个表中选择错误   类Java问题使用类加载器重新加载代码   java如何在Spring非管理类上使用@Value   java(关闭)Gradle导入VS代码失败   java arraylist拆分(“空白”)并计算字数   Android/Java如何在单独的*中调用函数。java文件?   具有基本身份验证的java Apache Camel RSS模块   java为什么程序在出现溢出或下溢时不抛出异常