=== Salamgate – سلام گیت ===
Contributors: alimohammadidev
Tags: سلام گیت, ارسال پستی, woocommerce, shipping, basalam
Requires at least: 6.2
Tested up to: 7.1
Requires PHP: 7.4
Stable tag: 1.0.0
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Ship WooCommerce, manual and Basalam orders with Iran Post at a discount, right from WordPress: instant tracking codes and label printing.

== Description ==

سلام‌گیت (سلام گیت) سرویس ارسال پستی باسلامه. با این افزونه، بدون رفتن به اداره پست و بدون صف، سفارش‌هات رو از داخل همون پیشخوان وردپرس ثبت می‌کنی، هزینهٔ ارسال رو می‌پردازی و برچسب پستی و کد رهگیری می‌گیری.

* **سفارش‌های سایت:** سفارش‌های ووکامرس رو تکی یا گروهی بفرست؛ اطلاعات گیرنده خودش پر می‌شه.
* **سفارش دستی:** فروش حضوری، اینستاگرام و تلگرام رو هم ثبت و ارسال کن.
* **سفارش‌های باسلام:** سفارش‌های غرفه‌ت رو ببین، تأیید کن و بفرست.
* **تخفیف پست:** قیمت روش‌های ارسال رو مقایسه کن و با تخفیف پست ارزون‌تر بفرست.
* **پرداخت آسان:** هزینه از کیف پول باسلام یا تراز غرفه کم می‌شه.
* **برچسب و کد رهگیری:** برچسب رو تکی یا برای یک بازهٔ تاریخ چاپ کن؛ کد رهگیری روی سفارش ثبت می‌شه و مشتری هم می‌بینه.

معرفی کامل: [salam-gate.basalam.com/plugins](https://salam-gate.basalam.com/plugins)

= English =

Salamgate is Basalam's shipping service for Iranian sellers. Ship WooCommerce orders, manual orders (in-person, Instagram, Telegram) and Basalam booth orders with Iran Post from the WordPress dashboard: compare Post prices, pay from your Basalam wallet or booth balance, print labels and track parcels.

= Requirements =

* A Basalam account with a booth (vendor).
* WooCommerce is optional; without it you can still ship manual and Basalam orders.

== External services ==

This plugin is a client for Basalam's services. It does not work without them. Requests are sent only after the site administrator connects a Basalam account in the plugin settings, and only from the WordPress admin or the plugin's scheduled status sync.

**Basalam login (salam-gate.basalam.com, basalam.com/accounts/sso)**
Used to connect the site to the administrator's Basalam account (OAuth 2.0) when they press "connect". The browser goes to salam-gate, which shows the site's address and asks for confirmation, then signs the administrator in on Basalam. The site's admin address and a one-time random value are sent; the access token comes back to the site's admin page and is stored in the site's database.

**Salamgate (salam-gate.basalam.com)**
The shipping service itself. Receiver details (name, mobile, address, postal code, city), parcel details (weight, value, packaging, items) and the chosen Post service are sent when you create, price, pay for, cancel, track or print a parcel, and when you register a send origin. Parcel statuses are requested twice a day when automatic status sync is enabled.

**Basalam core and order processing (core.basalam.com, order-processing.basalam.com)**
Used to read the connected account and booth, and to list and confirm the booth's Basalam orders when you open the Basalam orders page.

**Basalam wallet and accounting (wallet.basalam.com, accounting.basalam.com)**
Used to show the wallet and booth balance on the payment page. Only the access token is sent.

These services are provided by Basalam: [terms of use and privacy](https://basalam.com/about/terms-of-use).

Tracking codes link to the Iran Post tracking page (tracking.post.ir); nothing is sent to it unless you or your customer open the link.

== Installation ==

1. Upload the `salamgate` folder to `/wp-content/plugins/`, or install the zip from Plugins → Add New.
2. Activate the plugin.
3. Open **سلام‌گیت** (Salamgate) and press "connect to Basalam"; sign in with the Basalam account that owns your booth.
4. Register or activate a send origin under **سلام‌گیت → مبدأهای ارسال** (Send origins).

== Frequently Asked Questions ==

= Is WooCommerce required? =

No. Without WooCommerce you can still ship manual orders and Basalam orders.

= Which currency are prices shown in? =

Salamgate works in Rial; amounts are shown in your WooCommerce currency (Rial or Toman).

= Where are the tracking codes saved? =

On the WooCommerce order. The customer sees the tracking code and a link to the Post tracking page in their account.

== Changelog ==

= 1.0.0 =
* First release.

== Upgrade Notice ==

= 1.0.0 =
First release.
