Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How can I see the tickets Assigned to my Group? #43

Open
prophaner opened this issue Apr 15, 2015 · 6 comments
Open

How can I see the tickets Assigned to my Group? #43

prophaner opened this issue Apr 15, 2015 · 6 comments

Comments

@prophaner
Copy link

In the GUI, I have a way to see 'Tickets Assigned to my groups', then they all have in common the 'AdminCc (group)' header. How can I make this search using the API, if is possible?

@z4r
Copy link
Owner

z4r commented Apr 17, 2015

Hi @prophaner ,
the url to call is something like: /REST/1.0/search/ticket?query=AdminCc="YOURGROUP"

So with the library will be:

try:
    response = resource.get(path='search/ticket?query=AdminCc="YOURGROUP"')
    logger.info(response.parsed)
except RTResourceError as e:
    logger.error(e.response.status_int)
    logger.error(e.response.status)
    logger.error(e.response.parsed)

You if need more info about queries: http://requesttracker.wikia.com/wiki/REST

@prophaner
Copy link
Author

Thanks for your reply. I was actually trying it that way, no success.

On Fri, Apr 17, 2015 at 1:45 PM, Andrea de Marco notifications@github.com
wrote:

Hi @prophaner https://github.com/prophaner ,
the url to call is something like:
/REST/1.0/search/ticket?query=AdminCc="YOURGROUP"

So with the library will be:

try:
response = resource.get(path='search/ticket?query=AdminCc="YOURGROUP"')
logger.info(response.parsed)except RTResourceError as e:
logger.error(e.response.status_int)
logger.error(e.response.status)
logger.error(e.response.parsed)

You if need more info about queries:
http://requesttracker.wikia.com/wiki/REST


Reply to this email directly or view it on GitHub
#43 (comment).

Regards,
Luis M. Ramos Aguilar

@prophaner
Copy link
Author

Andrea, I just forked your code, maybe I can contribute.

On Fri, Apr 17, 2015 at 2:13 PM, Luis Ramos lmramos89@gmail.com wrote:

Thanks for your reply. I was actually trying it that way, no success.

On Fri, Apr 17, 2015 at 1:45 PM, Andrea de Marco <notifications@github.com

wrote:

Hi @prophaner https://github.com/prophaner ,
the url to call is something like:
/REST/1.0/search/ticket?query=AdminCc="YOURGROUP"

So with the library will be:

try:
response = resource.get(path='search/ticket?query=AdminCc="YOURGROUP"')
logger.info(response.parsed)except RTResourceError as e:
logger.error(e.response.status_int)
logger.error(e.response.status)
logger.error(e.response.parsed)

You if need more info about queries:
http://requesttracker.wikia.com/wiki/REST


Reply to this email directly or view it on GitHub
#43 (comment).

Regards,
Luis M. Ramos Aguilar

Regards,
Luis M. Ramos Aguilar

@z4r
Copy link
Owner

z4r commented Apr 18, 2015

you are welcome ;)
I succest you to start from a working url in the browser ;)

@prophaner
Copy link
Author

Andrea, I commited a fix to a few PEP items. I also suggest to replace the
name of some arguments as they start with Capital and they should be all
lowercase. Like 'Queue'.

On Sat, Apr 18, 2015 at 4:08 AM, Andrea de Marco notifications@github.com
wrote:

you are welcome ;)


Reply to this email directly or view it on GitHub
#43 (comment).

Regards,
Luis M. Ramos Aguilar

@z4r
Copy link
Owner

z4r commented Apr 19, 2015

Make your Pull Request so I can see these suggestions ;)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants