github.com/mhilton/juju-juju@v0.0.0-20150901100907-a94dd2c73455/doc/annotations_client.txt (about) 1 # ANNOTATION CLIENT 2 3 New annotations client is available from 1.22 effectively deprecating 4 annotations in old client. 5 6 This client provides functionality to annotate charms in addition 7 to environment, machine, service and unit previously done 8 through our old client. 9 10 New annotations client also supports bulk calls. 11 12 ## API 13 14 Note that where SET call returns an error, Error in GET call return is params.ErrorResult. 15 16 ### SET 17 For the SET annotations call that looks similar to this: 18 19 ......{ 20 "Type": "Annotations", 21 "Request": "Set", 22 "Params": { 23 "Annotations": {{ 24 "EntityTag": a, "Annotations": pairs1 25 },{ 26 "EntityTag": b, "Annotations": pairs2 27 }} 28 }}...... 29 ### GET 30 Corresponding GET annotations call may look like: 31 32 ......{ 33 "Type": "Annotations", 34 "Request": "Get", 35 "Params": { 36 "Entities": { 37 {Entity {"Tag": a}}, 38 {Entity {"Tag": b}, 39 } 40 }}...... 41 42 Returning 43 44 { 45 "Results": { 46 {"EntityTag": a, "Annotations": pairs1, "Error": nil}, 47 {"EntityTag": b, "Annotations": pairs2, "Error": nil}, 48 49 }}