View Revisions: Issue #26121

Summary 0026121: Problem creating issues with custom fields using REST API
Revision 2019-09-09 10:49 by dregad
Description

I'm trying to create new issues using Mantis REST API but I'm getting a problem with custom fields, I'm following guidlines from Postman and sending that data in json:

{
    'summary': 'Test_summary', 
    'project': {'id': '123'}, 
    'custom_fields': [
        {
        'field': {'name': 'IP name'}
        'value': 'Test', 
        }, 
        {
        'field': {'name': 'Other'}}
        'value': 'MISC', 
        ], 
    'description': 'Test_summary', 
    'category': {'name': 'RnD Env'}
}

But I'm getting answer back that custom field is empty:

"Invalid custom field 'IP name' value.","code":11,"localized":"A necessary field \"IP name\" was empty. Please recheck your inputs."

Mantis v. 2.22 but same problem was present in previous install v 2.14

EDIT [dregad] Markdown block quote

Revision 2019-09-09 05:27 by eaaswrm
Description

I'm trying to create new issues using Mantis REST API but I'm getting a problem with custom fields, I'm following guidlines from Postman and sending that data in json:

{
'summary': 'Test_summary',
'project': {'id': '123'},
'custom_fields': [
{
'field': {'name': 'IP name'}
'value': 'Test',
},
{
'field': {'name': 'Other'}}
'value': 'MISC',
],
'description': 'Test_summary',
'category': {'name': 'RnD Env'}
}

But I'm getting answer back that custom field is empty:

"Invalid custom field 'IP name' value.","code":11,"localized":"A necessary field \"IP name\" was empty. Please recheck your inputs."

Mantis v. 2.22 but same problem was present in previous install v 2.14