0

I am using redmine rest api with c# and I have a problem with custom fields. I have this method:

NameValueCollection parameters = new NameValueCollection { { RedmineKeys.INCLUDE, RedmineKeys.CUSTOM_FIELDS} };
            var projectInfo = manager.GetObject<Redmine.Net.Api.Types.Project>("1", parameters);

From that I can get project info but the custom fields are always null. I have one custom field (email) that appears in all new issues and I can get it from issue. I would like to get all custom fields that are in the project.

What am I doing wrong?

AlG
  • 14,697
  • 4
  • 41
  • 54

1 Answers1

0

Here is the solution if anybody needs it.

 NameValueCollection queryParameters = new NameValueCollection { { RedmineKeys.PROJECT_ID, "1" } };


            var GetTickets = manager.GetObjects<Redmine.Net.Api.Types.CustomField>(queryParameters);

Just to mention "Project_ID" don't do anything I always get all custom fields in redmine projects. Will try to find out how to get custom fields from specific project.