cancel
Showing results for 
Search instead for 
Did you mean: 

phone column not showing telephone number provided using rest api customer datag in customer table

SOLVED

phone column not showing telephone number provided using rest api customer datag in customer table

Hi i m using rest apis to register the customer, but after sending telephone number, the phone column not showing telephone number in the customer datagrid.

1 ACCEPTED SOLUTION

Accepted Solutions

Re: phone column not showing telephone number provided using rest api customer datag in customer tab

Hi @akshay_kapase

 

I have checked this and that is correct behavior , if you wanted to show that telephone number into customer grid , then the address you are passing must selected as a default_billing and default_shipping address.

 

so here  you are passing the parameter that is correct but along with this you need to pass default_billing and default_shipping parameter with your address.

 

below is the updated parameters code : 

 

{ "customer": { 
	
	"email": "tesasast@gmail.com", "firstname": "uname", "lastname": "null", 
	 "default_billing": "true",
    "default_shipping": "true",
	"addresses": [
	{
		"company": "xyz",
		"telephone": "2984923422",
		"firstname": "Hello",
		"lastname": "World",
		"street":[
			"123 Main Street",
			"PO Box 321"
		],
		"city":"test",
		"postcode":"12345",
		"countryId":"IN",
		"default_shipping": true,
        "default_billing": true
	}
	] 
	
},

"password":"123123"
}

Just copy above given parameters and replace with your one.

 

then check customer telephone will display in the grid.

 

it will works !

if issue solved,Click Kudos & Accept as Solution

View solution in original post

3 REPLIES 3

Re: phone column not showing telephone number provided using rest api customer datag in customer tab

Hi @akshay_kapase

 

AKAIK , phone column is not available on standard magento 2 registration form screen.

 

still , could you please post here which URL you are calling ? and which parameters you are passing to create customer ?

 

post those details , so its helps us to troubleshoot the issue.

if issue solved,Click Kudos & Accept as Solution

Re: phone column not showing telephone number provided using rest api customer datag in customer tab

Im using rest api

{ "customer": { "email": "test@gmail.com", "firstname": "uname", "lastname": "null", "addresses": [
{
"company": "xyz",
"telephone": "2984923422",
"firstname": "Hello",
"lastname": "World",
"street":[
"123 Main Street",
"PO Box 321"
],
"city":"test",
"postcode":"12345",
"countryId":"IN"
}
] },"password":"123123" }

 

And phone column is showing in the admin side of the magento 2 customer panel but the telephone number is not showing up which was sent using the rest api.

Re: phone column not showing telephone number provided using rest api customer datag in customer tab

Hi @akshay_kapase

 

I have checked this and that is correct behavior , if you wanted to show that telephone number into customer grid , then the address you are passing must selected as a default_billing and default_shipping address.

 

so here  you are passing the parameter that is correct but along with this you need to pass default_billing and default_shipping parameter with your address.

 

below is the updated parameters code : 

 

{ "customer": { 
	
	"email": "tesasast@gmail.com", "firstname": "uname", "lastname": "null", 
	 "default_billing": "true",
    "default_shipping": "true",
	"addresses": [
	{
		"company": "xyz",
		"telephone": "2984923422",
		"firstname": "Hello",
		"lastname": "World",
		"street":[
			"123 Main Street",
			"PO Box 321"
		],
		"city":"test",
		"postcode":"12345",
		"countryId":"IN",
		"default_shipping": true,
        "default_billing": true
	}
	] 
	
},

"password":"123123"
}

Just copy above given parameters and replace with your one.

 

then check customer telephone will display in the grid.

 

it will works !

if issue solved,Click Kudos & Accept as Solution