Comments (5)
Here is a working example which was passed on to me privately.
import requests
s = requests.Session()
s.auth = (zendesk.zdesk_email, zendesk.zdesk_password)
article_id = '202794701'
result = s.post(zendesk_url +
'/api/v2/help_center/articles/' + article_id + '/attachments.json',
params = {'inline':'true'},
files = {'file': (fname, open(fname, 'rb'), 'image/png')})
from zdesk.
I was thinking about forking this repo to use requests. Thanks for saving me the trouble.
👍 for moving to use requests
from zdesk.
While it is completely untested I've started on this: https://github.com/fprimex/zdesk/tree/requests
I have not yet begun to address the file upload issue. Just working to achieve the current functionality with requests rather than httplib2.
from zdesk.
I've forked zdesk to help you with the work on replacing urllib with requests
from zdesk.
This is done with the 2.3.0 release which has just been made.
from zdesk.
Related Issues (20)
- Unable to query users HOT 1
- Support for max_retries missing in current 2.4.0 release. HOT 6
- Unable to delete user group membership HOT 1
- RFC from community on 2.5.0 release from HEAD HOT 1
- macro_create choking with 500 error, and HTML response HOT 3
- get_all_pages not working properly for incremental loads HOT 5
- Pagination query HOT 2
- Support of OAuth tokens HOT 7
- How should we use "get_all_pages" to import all tickets? HOT 2
- ImportError: cannot import name Zendesk HOT 3
- Add sideload for ticket_events HOT 1
- Finding tag from a ticketID HOT 1
- Importing zdesk Syntax Error HOT 3
- issue with python 3.7 HOT 1
- Which version is supported the new announced DDoS protection system? HOT 1
- AuthenticationError HOT 1
- Importing ABC from collections has been deprecated and will be removed in Python 3.10
- Message=attempted relative import with no known parent package HOT 2
- `users_search()` produces malformed URL query string in 2.8.0 HOT 5
- zdesk tickets_list query filter examples HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from zdesk.