Get the checkout URL to change a product for a subscription.

@param string $subscriptionId The subscription ID.
@param string $articleNumber The new article number.
@return string
17141
protected function generateSubscriptionProductChangeURL($subscriptionId, $articleNumber)
    {
        return sprintf(
            'https://app.monsum.com/change/%s/%s/%s',
            $this->transport->getCredentials()->getAccountHash(),
            $subscriptionId,
            $articleNumber
        );
    }
482207
public function getBannerArticle()
    {
        $sArtId = $this->fetchBannerArticleId();

        if ($sArtId) {
            $oArticle = oxNew(\OxidEsales\Eshop\Application\Model\Article::class);

            if ($this->isAdmin()) {
                $oArticle->setLanguage(\OxidEsales\Eshop\Core\Registry::getLang()->getEditLanguage());
            }

            if ($oArticle->load($sArtId)) {
                return $oArticle;
            }
        }

        return null;
    }
56385
public function getSubscriptionByCustomerId($customerId)
    {
        /** @var SubscriptionFbApi $response */
        $response = $this->call(new Request('subscription.get', array('customer_id' => $customerId)), 'DVelopment\FastBill\Model\SubscriptionFbApi');
        $subscriptions = $response->getResponse()->getSubscriptions();

        return reset($subscriptions);
    }
1102755
public function get_discussion_subscribe_url(discussion_entity $discussion) : moodle_url {
        return new moodle_url('/mod/forum/subscribe.php', [
            'sesskey' => sesskey(),
            'id' => $discussion->get_forum_id(),
            'd' => $discussion->get_id()
        ]);
    }
244734
public function getArticles($articleNumber = null)
    {
        $requestData = new Get\RequestData();
        $requestData->setArticleNumber($articleNumber);

        $request = new Get\Request($requestData);

        return $this->sendRequest($request, Get\ApiResponse::class);
    }
305780
def get_subscription(self, subscription_id):
        
        return self.client._put(self.url + 'subscriptions/{}'.format(subscription_id), headers=self.get_headers())
826740
private function getArticleForPage(ArticleDocument $article, $pageNumber)
    {
        $children = $article->getChildren();
        if (null === $children || 1 === $pageNumber) {
            return $article;
        }

        foreach ($children as $child) {
            if ($child instanceof ArticlePageDocument && $child->getPageNumber() === $pageNumber) {
                return $child;
            }
        }

        return $article;
    }
541247
public function forSubscription($subscriptionId)
    {
        $service = $this->getService();

        // events for a subscription
        $response = $service->request('subscriptions/' . $subscriptionId . '/events', 'GET', NULL, $this->getParams());

        $responseArray = $this->getResponseArray($response);

        if (!$this->isError()) {
            $this->_data = $this->_normalizeResponseArray($responseArray);
        } else {
            $this->_data = array();
        }

        return $this;
    }
666284
public function upcomingInvoice($customerId, $subscriptionId = null, array $parameters = [])
    {
        $parameters = array_merge($parameters, [
            'customer'     => $customerId,
            'subscription' => $subscriptionId,
        ]);

        return $this->_get('invoices/upcoming', $parameters);
    }
876466
public function createDraftFromVersion($contentId, $versionNumber)
    {
        $contentInfo = $this->repository->getContentService()->loadContentInfo($contentId);
        $contentType = $this->repository->getContentTypeService()->loadContentType($contentInfo->contentTypeId);
        $contentDraft = $this->repository->getContentService()->createContentDraft(
            $contentInfo,
            $this->repository->getContentService()->loadVersionInfo($contentInfo, $versionNumber)
        );

        return new Values\CreatedVersion(
            array(
                'version' => new Values\Version(
                    $contentDraft,
                    $contentType,
                    $this->repository->getContentService()->loadRelations($contentDraft->getVersionInfo())
                ),
            )
        );
    }
814083
function version_upgrade_checkout_link( $new_version ) {
            if ( ! is_object( $this->_license ) ) {
                $url = $this->pricing_url();

                $purchase_license_text = $this->get_text_inline( 'Buy a license now', 'buy-license-now' );
            } else {
                $subscription = $this->_get_subscription( $this->_license->id );

                $url = $this->checkout_url(
                    is_object( $subscription ) ?
                        ( 1 == $subscription->billing_cycle ? WP_FS__PERIOD_MONTHLY : WP_FS__PERIOD_ANNUALLY ) :
                        WP_FS__PERIOD_LIFETIME,
                    false,
                    array( 'licenses' => $this->_license->quota )
                );

                $purchase_license_text = $this->get_text_inline( 'Renew your license now', 'renew-license-now' );
            }

            return sprintf(
                $this->get_text_inline( '%s to access version %s security & feature updates, and support.', 'x-for-updates-and-support' ),
                sprintf( '<a href="%s">%s</a>', $url, $purchase_license_text ),
                $new_version
            );
        }
55034
public function loadManufacturerArticles($sManufacturerId, $oManufacturer = null)
    {
        $sSelect = $this->_getManufacturerSelect($sManufacturerId);
        $this->selectString($sSelect);

        return \OxidEsales\Eshop\Core\Registry::getUtilsCount()->getManufacturerArticleCount($sManufacturerId);
    }
1107763
public function setQuantityAllocation($subscriptionId, $componentId)
    {
        $service       = $this->getService();
        $rawData       = $this->getRawData(array('component' => $this->_params));
        $response      = $service->request('subscriptions/' . (int)$subscriptionId . '/components/' . (int)$componentId, 'PUT', $rawData);
        $responseArray = $this->getResponseArray($response);

        if (!$this->isError()) {
            $this->_data = $responseArray['component'];
        } else {
            $this->_data = array();
        }

        return $this;
    }
260847
public function checkCoupon($code, $articleNumber)
    {
        $requestData = new Check\RequestData($code, $articleNumber);
        $request = new Check\Request($requestData);

        return $this->sendRequest($request, Check\ApiResponse::class);
    }
1111671
public function getUnsubscribeFrame($destination, $subscriptionId = null)
    {
        $frame = $this->createFrame('UNSUBSCRIBE');
        $frame['destination'] = $destination;
        $frame['id'] = $subscriptionId;
        return $frame;
    }
956131
public function getSubscriptionUsageData(
        $subscriptionId,
        \DateTime $subscriptionStart = null,
        \DateTime $subscriptionEnd = null
    ) {
        $requestData = new GetUsageData\RequestData($subscriptionId);

        $requestData->setSubscriptionId($subscriptionId);
        $requestData->setSubscriptionStart($subscriptionStart);
        $requestData->setSubscriptionEnd($subscriptionEnd);

        $request = new GetUsageData\Request($requestData);

        return $this->sendRequest($request, GetUsageData\ApiResponse::class);
    }
416666
public function subscribe($destination, $subscriptionId = null, $ack = 'auto', $selector = null, array $header = [])
    {
        return $this->client->sendFrame(
            $this->getProtocol()->getSubscribeFrame($destination, $subscriptionId, $ack, $selector)->addHeaders($header)
        );
    }