{"id":20251577,"url":"https://github.com/williamsmithedward/andromedatm1sharp","last_synced_at":"2026-02-09T08:36:41.922Z","repository":{"id":186417794,"uuid":"665588015","full_name":"WilliamSmithEdward/AndromedaTM1Sharp","owner":"WilliamSmithEdward","description":"AndromedaTM1Sharp is a .Net API interface for IBM's TM1 and Planning Analytics with Watson OData v4 REST APIs.","archived":false,"fork":false,"pushed_at":"2025-02-11T11:50:37.000Z","size":97,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-07-20T09:31:13.863Z","etag":null,"topics":["ibm","mdx","olap","paw","planning-analytics","rest-api","tm1","turbo-integrator"],"latest_commit_sha":null,"homepage":"https://www.nuget.org/packages/AndromedaTM1Sharp","language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/WilliamSmithEdward.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2023-07-12T14:32:17.000Z","updated_at":"2025-02-11T11:50:41.000Z","dependencies_parsed_at":null,"dependency_job_id":"6a12da5a-7949-4b34-9410-4b563f1099ed","html_url":"https://github.com/WilliamSmithEdward/AndromedaTM1Sharp","commit_stats":null,"previous_names":["williamsmithedward/andromedatm1sharp"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/WilliamSmithEdward/AndromedaTM1Sharp","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/WilliamSmithEdward%2FAndromedaTM1Sharp","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/WilliamSmithEdward%2FAndromedaTM1Sharp/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/WilliamSmithEdward%2FAndromedaTM1Sharp/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/WilliamSmithEdward%2FAndromedaTM1Sharp/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/WilliamSmithEdward","download_url":"https://codeload.github.com/WilliamSmithEdward/AndromedaTM1Sharp/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/WilliamSmithEdward%2FAndromedaTM1Sharp/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":267552097,"owners_count":24106000,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-07-28T02:00:09.689Z","response_time":68,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["ibm","mdx","olap","paw","planning-analytics","rest-api","tm1","turbo-integrator"],"created_at":"2024-11-14T10:10:58.858Z","updated_at":"2026-02-09T08:36:41.851Z","avatar_url":"https://github.com/WilliamSmithEdward.png","language":"C#","funding_links":[],"categories":[],"sub_categories":[],"readme":"# AndromedaTM1Sharp\nAuthor: William Smith  \nE-Mail: williamsmithe@icloud.com\n\n## Version 1.0.18 Update\n* Increased number of dimension+element parameters to 20 for QueryCellAsync method.\n* Methods that create a cellset on the TM1 server will now send a cellset delete API call to clear the cellset from memory after the data has been read.\n\n## Reading a value from a single cube cell\nExample of reading the value of a single cell from a cube.\n\n```csharp\nusing AndromedaTM1Sharp;\n\nvar tm1Config = new TM1SharpConfig(\"https://YourTM1Server:YourPort\", \"tm1UserName\", \"tm1Password\", \"YourEnvName\");\n\nList\u003cstring\u003e lookupValues = new List\u003cstring\u003e()\n{\n    \"Lookup_Value_01\",\n    \"Lookup_Value_02\",\n    \"Lookup_Value_03\"\n};\n\nlookupValues.ForEach(async x =\u003e\n{\n    var result = await TM1RestAPI.QueryCellAsync(tm1Config, \"Cube_Name\", \"Dimension_01\", x, \"Dimension_02\", \"Element_02\");\n\n    Console.WriteLine(result);\n});\n```\n\n## Reading from an MDX query\nExample of running an MDX query to return data. Escape double quote with \\\\\\\\\\\\\\\"VALUE\\\\\\\\\\\\\\\" (send literal \\\\\\\"VALUE\\\\\\\").\nSee https://www.ibm.com/docs/en/planning-analytics/2.0.0?topic=data-cellsets for details on JSON structure.\n\n```csharp\nusing AndromedaTM1Sharp;\n\nvar tm1Config = new TM1SharpConfig(\"https://YourTM1Server:YourPort\", \"tm1UserName\", \"tm1Password\", \"YourEnvName\");\n\nstring mdx = \"SELECT {[DIMENSION1].[HIERARCHY].[ELEMENT]} ON 0, {[DIMENSION2].[HIERARCHY].[ELEMENT]} ON 1 FROM [YourCube]\";\n\nvar content = await TM1RestAPI.QueryMDXAsync(tm1Config, mdx);\n\nConsole.WriteLine(content);\n```\n\n## Reading from a cube view\nExample of reading a cellset from a cube view.  \nSee https://www.ibm.com/docs/en/planning-analytics/2.0.0?topic=data-cellsets for details on JSON structure.\n\n```csharp\nusing AndromedaTM1Sharp;\n\nvar tm1Config = new TM1SharpConfig(\"https://YourTM1Server:YourPort\", \"tm1UserName\", \"tm1Password\", \"YourEnvName\");\n\nvar content = await TM1RestAPI.QueryViewAsync(tm1Config, \"YourCube\", \"YourView\");\n\nConsole.WriteLine(content);\n```\n\n## Converting cellset JSON to System.Data.DataTable\nExample of deserializing and converting the JSON return from a View / MDX query to a DataTable.  \nCurrently supports multiple hierarchy levels on rows.\n\n```csharp\nusing AndromedaTM1Sharp;\nusing System.Data;\n\nvar tm1Config = new TM1SharpConfig(\"https://YourTM1Server:YourPort\", \"tm1UserName\", \"tm1Password\", \"YourEnvName\");\n\nstring mdx = @\"Your_MDX_Statement\";\n\nvar content = await TM1RestAPI.QueryMDXAsync(tm1Config, mdx);\n\nvar model = CellsetJSONParser.ParseIntoObject(content);\n\nvar dt = model?.ToDataTable();\n\nforeach (DataRow row in dt.Rows)\n{\n    foreach (DataColumn column in dt.Columns)\n    {\n        Console.WriteLine(column.ColumnName + \": \" + row[column]);\n    }\n\n    Console.WriteLine();\n}\n```\n\n## Writing to a cube\nExample of writing a list of values to a cube, while iterating through one dimension and keeping other dimensions constant. \n\n```csharp\nusing AndromedaTM1Sharp;\n\nvar tm1Config = new TM1SharpConfig(\"https://YourTM1Server:YourPort\", \"tm1UserName\", \"tm1Password\", \"YourEnvName\");\n\nvar cubeUpdateKVPList = new List\u003cKeyValuePair\u003cstring, string\u003e\u003e()\n{\n    new KeyValuePair\u003cstring, string\u003e(\"9208\", \"value1\"),\n    new KeyValuePair\u003cstring, string\u003e(\"9209\", \"value2\"),\n    new KeyValuePair\u003cstring, string\u003e(\"9210\", \"value3\"),\n    new KeyValuePair\u003cstring, string\u003e(\"9211\", \"value4\"),\n    new KeyValuePair\u003cstring, string\u003e(\"9212\", \"value5\")\n};\n\nvar cellReferenceList = new List\u003cCellReference\u003e();\n\ncubeUpdateKVPList.ForEach(x =\u003e\n{\n    cellReferenceList.Add(\n        new CellReference(new List\u003cElementReference\u003e()\n        {\n            new ElementReference(\"REGION\", \"REGION\", \"Massachusets\"),\n            new ElementReference(\"MONTH\", \"MONTH\", x.Key),\n            new ElementReference(\"PROJECT\", \"PROJECT\", \"PROJECT NAME\")\n        }, x.Value\n    ));\n});\n\nawait TM1RestAPI.WriteCubeCellValueAsync(tm1Config, \"YourCube\", cellReferenceList);\n```\n\n## Querying a list of cubes\nExample of reading a list of cubes from the TM1 server.\n\n```csharp\nusing AndromedaTM1Sharp;\n\nvar tm1Config = new TM1SharpConfig(\"https://YourTM1Server:YourPort\", \"tm1UserName\", \"tm1Password\", \"YourEnvName\");\n\nvar content = await TM1RestAPI.QueryCubeListAsync(tm1Config);\n\nConsole.WriteLine(content);\n```\n\n## Querying the dimensions of a cube\nExample of querying the dimensions of a cube.\n\n```csharp\nusing AndromedaTM1Sharp;\n\nvar tm1Config = new TM1SharpConfig(\"https://YourTM1Server:YourPort\", \"tm1UserName\", \"tm1Password\", \"YourEnvName\");\n\nvar content = await TM1RestAPI.QueryCubeDimensionsAsync(tm1Config, \"YourCube\");\n\nConsole.WriteLine(content);\n```\n\n## Running a Turbo Integrator process\nExample of running a TI process on the TM1 server. Expected return payload is:  \n{\"@odata.context\":\"../$metadata#ibm.tm1.api.v1.ProcessExecuteResult\",\"ProcessExecuteStatusCode\":\"CompletedSuccessfully\"}\n\n```csharp\nusing AndromedaTM1Sharp;\n\nvar tm1Config = new TM1SharpConfig(\"https://YourTM1Server:YourPort\", \"tm1UserName\", \"tm1Password\", \"YourEnvName\");\n\nvar content = await TM1RestAPI.RunProcessAsync(tm1Config, \"_CreateCubeProcess\", new Dictionary\u003cstring, string\u003e() { { \"CubeName\", \"_NewCubeCreatedbyRestAPI\" } });\n\nConsole.WriteLine(content);\n```\n\n# Attributions\nNuGet icon \"AndromedaTM1Sharp.png\" designed by Freepik Company S.L. \u003chttps://support.freepik.com/\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwilliamsmithedward%2Fandromedatm1sharp","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fwilliamsmithedward%2Fandromedatm1sharp","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwilliamsmithedward%2Fandromedatm1sharp/lists"}