Comment-based and name-based filters
Get a list of filters assigned to a specific customer
Request
GET http://localhost:8080/fpc/api/customers/{cid}/commentnamebasedfilters
Headers
accept: application/json
content-type: application/json
fpc-sid: $FPCSID
Cookie: fpc-jsessionid=$FPCSID
Response
{
"customerId" : 6,
"commentBasedFilter" : ["new1", "hello1"],
"nameBasedFilter" : ["go", "good"]
}
Update the filters assigned to a specific customer
Request
POST http://localhost:8080/fpc/api/customers/{cid}/commentnamebasedfilters
Headers
accept: application/json
content-type: application/json
fpc-sid: $FPCSID
Cookie: fpc-jsessionid=$FPCSID
Payload
{
"customerId" : 6,
"commentBasedFilter" : ["new filters", "pfilter"],
"nameBasedFilter" : ["objfilter1", "cs22"]
}
Response
Status 200 OK
Validation
If domain names are not unique, more than 10, or does not satisfy characters criteria, it will respond as Status 400 Bad Request and with message as follows:
- {"domainNames": "Domain Name must be unique, xyz.com,def.com already exists"}
- {"domainNames": "Domain Name (xdfd23232!@#yzcom) is Invalid"}
- { "domainNames": "Domain Names count reached max limit of 10"}