How to Add/Update shipping address of customer usnig REST Api in Magento 2 - magento2

I want to Add/Update/Delete shipping address of the specific customer (using auth token) using REST API in magento2. Is any API endpoint available for that?

You can get customer shipping address and delete it by using Magento 2 default rest API endpoints. You can check details here. vendor/magento/module-customer/etc/webapi.xml
To get shipping address by customer ID
/V1/customers/:customerId/shippingAddress
To delete shipping address by address id (you should get the address id from above endpoint).
/V1/addresses/:addressId
So, if you want to add & edit, you should create a basic module where you can define custom endpoints and methods.
If you want to know how to create custom rest api in Magento 2 you can check this out.
https://magento.stackexchange.com/questions/282480/i-am-new-here-i-want-to-know-how-can-i-create-my-own-simple-api

Related

Get information about customer without password of user using the Shopware 6 REST API

I am trying to get information about a customer using the REST API of Shopware 6 (using this API). Therefor I need a ContextToken for that user. The only way to get a context token for a user is to log him in, but for that I need the password of a user which I do not have. Is there any way to get the ContextToken of a user with only his email address or hist customer id?
Shopware comes with 2 different APIs, the Store-API and the Admin-API. Refer to the docs.
The Store-API is there to build a storefront and thus you need to authenticate as the user using that API.
When you build custom integrations you should use the Admin-API, as that API can be used for CRUD-like operations on all entities of the system. For the admin API you can generate an API-Token and use it to query data of all customers.

How to get the list all users in confluence using rest API

I am trying to get the list of all users with their email addresses from a confluence cloud instance using their REST API. There is nothing in their documentation regarding users. Also the email address is never embedded in any of the response containing user objects. Is there a way to retrieve email address of the user based on the username.
You will have to use their older APIs -- the methods are there.

Broadleaf : Not able to save shipping address using rest

I am working with rest api of broadleaf eCommerce. I need to complete checkout process with rest api of broadleaf. I am using " /cart/checkout/payment: POST" to initiate check out process. But with this rest I am only able to save billingAddres not shippingAddress. It is required to save shippingAddres to complete checkout process. I have also tried to extend entity and wrapper class of broadleaf. But not getting success.
What should I do to save shipping address? or, Is it possible to save shippingAddress with rest api of broaleaf.
The shipping address is bound to a chosen fulfilment group for that particular order, so you might need to use the endpoint
/cart/fulfillment/group
to set the fulfilment group, fulfilment option and the related shipping address.
More info on the endpoints can be found in the REST section of the broadleaf documentation.

How Can I Get the attribute[special_from_date] from Magento Rest API without Authentication

I'd like to get the product attributes including special_from_date,news_from_date and special_price from REST API without the authentication steps(Now these REST Attributes are only available for admin).So that guests can get product attributes info just througth the link http://me.magento/api/rest/products?categories=42.Anyone can Help,Please?
Navigate to System -> Web Services -> Rest - Attribute
Select customer or Guest to choose your desired attribute for the products.

How to pre-fill customer details using Paypal REST API?

We're using Paypal's REST API and we'd like to pre-fill the customer's data (email, name, address) on the approval's page.
There is a payer_info object that can passed to Paypal when the payment is created. But it does not allow specifying customer's details - email field is not supported and others are read-only. Also I don't see any mentions in the API docs on how to achieve this with the REST API. Do you know if it's possible and how? If it's not supported, is it known when it's gonna be supported?
Thanks in advance.
Even when using PayPal REST API you can follow these instructions https://www.paypal.com/cgi-bin/webscr?cmd=_pdn_xclick_prepopulate_outside and append the params as GET params on the end of the aproval_url before redirect the customer.
For example:
https://www.sandbox.paypal.com/cgi-bin/webscr?cmd=_express-checkout&token=EC-77D44712W7736393M&first_name=Geovanny&last_name=Junio