How to get the creator of an attachment using confluence REST api?

How do I get the creator of an attachment using confluence REST api?

http://confluence/rest/prototype/1/attachment/111111

gets this:

{
  "id": "111111",
  "type": "attachment",
  "ownerId": "xxxxxx",
  "parentTitle": "bla",
  "fileName": "bla.png",
  "contentType": "image/png",
  "fileSize": 162070,
  "niceFileSize": "158 kB",
  "version": 1,
  "niceType": "Image",
  "iconClass": "content-type-attachment-image",
  "title": "bla.png",
  "thumbnailLink": {
    "href": "http://confluence/download/thumbnails/11111/bla.png?api=v2",
    "rel": "thumbnail"
  },
  "thumbnailWidth": 300,
  "thumbnailHeight": 139,
  "wikiLink": "bla",
  "space": {
    "key": "bla",
    "name": "bla",
    "title": "bla",
    "type": "bla",
    "link": [
      {
        "href": "http://confluence/rest/prototype/1/space/bla",
        "rel": "self"
      }
    ]
  },
  "lastModifiedDate": {
    "friendly": "Feb 14, 2012",
    "date": "2012-02-14T04:27:43+1100"
  },
  "createdDate": {
    "friendly": "Feb 14, 2012",
    "date": "2012-02-14T04:27:43+1100"
  },
  "link": [
    {
      "href": "http://confluence/rest/prototype/1/attachment/11111",
      "rel": "self"
    },
    {
      "href": "http://confluence/download/attachments/8389284/bla.png?version=1&modificationDate=1329154063000&api=v2",
      "type": "image/png",
      "rel": "download"
    },
    {
      "href": "http://confluence/pages/viewpageattachments.action?pageId=222222&highlight=bla#bla.png",
      "type": "text/html",
      "rel": "alternate"
    }
  ]
}

Is there a call that exposes the creator? or call that can return the user by the ownerId?

3 answers

1 accepted

0 votes
Accepted answer

You cannot get that info via REST, it is a bug -- https://jira.atlassian.com/browse/CONF-33121

Use another remote API for now.

using this: 'http://confluence.fx.srv.westpac.com.au/rpc/json-rpc/confluenceservice-v2/getUser' from the creator id

Suggest an answer

Log in or Sign up to answer
Community showcase
Posted Monday in Confluence

Organizing your space just got easier - Page Tree Drag & Drop is here

Hi Community! I’m Elaine, Confluence Product Manager. You may have read my earlier post about page tree in space navigation sidebar. I'm excited to share another improvement that helps you organize ...

101 views 3 4
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you